From d21dc0d91c1b5004affbb8e468f604b64ff80666 Mon Sep 17 00:00:00 2001 From: "Jasper St. Pierre" Date: Tue, 25 Nov 2014 11:05:57 -0800 Subject: [PATCH] gtkcellarea: Optimize GtkStyleContext usage This is a bit bizarre, but the cell renderer can apply different flags from the actual style context, and we should use those instead of the widget flags. --- gtk/gtkcellarea.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gtk/gtkcellarea.c b/gtk/gtkcellarea.c index eb82de3efd..1ce312abf3 100644 --- a/gtk/gtkcellarea.c +++ b/gtk/gtkcellarea.c @@ -3561,7 +3561,7 @@ gtk_cell_area_inner_cell_area (GtkCellArea *area, g_return_if_fail (inner_area != NULL); context = gtk_widget_get_style_context (widget); - state = gtk_widget_get_state_flags (widget); + state = gtk_style_context_get_state (context); gtk_style_context_get_padding (context, state, &border); *inner_area = *cell_area; @@ -3611,7 +3611,7 @@ gtk_cell_area_request_renderer (GtkCellArea *area, g_return_if_fail (natural_size != NULL); context = gtk_widget_get_style_context (widget); - state = gtk_widget_get_state_flags (widget); + state = gtk_style_context_get_state (context); gtk_style_context_get_padding (context, state, &border); if (orientation == GTK_ORIENTATION_HORIZONTAL)