toolbar: Stop setting state flags on the style context for drawing

This commit is contained in:
Rui Matos 2011-12-22 00:12:37 +00:00
parent a1f72eb06c
commit 4011326388

View File

@ -858,16 +858,11 @@ gtk_toolbar_draw (GtkWidget *widget,
GtkToolbar *toolbar = GTK_TOOLBAR (widget);
GtkToolbarPrivate *priv = toolbar->priv;
GtkStyleContext *context;
GtkStateFlags state;
GList *list;
guint border_width;
border_width = gtk_container_get_border_width (GTK_CONTAINER (widget));
context = gtk_widget_get_style_context (widget);
state = gtk_widget_get_state_flags (widget);
gtk_style_context_save (context);
gtk_style_context_set_state (context, state);
gtk_render_background (context, cr, border_width, border_width,
gtk_widget_get_allocated_width (widget) - 2 * border_width,
@ -887,8 +882,6 @@ gtk_toolbar_draw (GtkWidget *widget,
priv->arrow_button,
cr);
gtk_style_context_restore (context);
return FALSE;
}