[gnome-builder/wip/chergert/perspective] Pass correct state to GtkStyleContext API



commit 4b872abbba2542be2a37ff816f7ad93948da5bed
Author: Timm B├Ąder <mail baedert org>
Date:   Sat Dec 5 01:08:48 2015 -0800

    Pass correct state to GtkStyleContext API

 libide/ide-tree.c |    7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)
---
diff --git a/libide/ide-tree.c b/libide/ide-tree.c
index 4989487..eef4552 100644
--- a/libide/ide-tree.c
+++ b/libide/ide-tree.c
@@ -851,18 +851,17 @@ ide_tree_style_updated (GtkWidget *widget)
   IdeTree *self = (IdeTree *)widget;
   IdeTreePrivate *priv = ide_tree_get_instance_private (self);
   GtkStyleContext *style_context;
-  GtkStateFlags flags;
 
   g_assert (IDE_IS_TREE (self));
 
   GTK_WIDGET_CLASS (ide_tree_parent_class)->style_updated (widget);
 
-  flags = gtk_widget_get_state_flags (widget);
-
   style_context = gtk_widget_get_style_context (widget);
   gtk_style_context_save (style_context);
   gtk_style_context_add_class (style_context, "dim-label");
-  gtk_style_context_get_color (style_context, flags, &priv->dim_foreground);
+  gtk_style_context_get_color (style_context,
+                               gtk_style_context_get_state (style_context),
+                               &priv->dim_foreground);
   gtk_style_context_restore (style_context);
 }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]