[nautilus/gnome-3-4] editable-label: fix selection color in backdrop state



commit f5b824abf3f3b9304d7a63fd52d3f96036dc91ff
Author: Cosimo Cecchi <cosimoc gnome org>
Date:   Tue Apr 24 12:22:05 2012 -0400

    editable-label: fix selection color in backdrop state
    
    Don't set the ACTIVE flag if we don't have focus, it just doesn't make
    sense.

 eel/eel-editable-label.c |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)
---
diff --git a/eel/eel-editable-label.c b/eel/eel-editable-label.c
index 2232685..496c19a 100644
--- a/eel/eel-editable-label.c
+++ b/eel/eel-editable-label.c
@@ -1598,9 +1598,8 @@ eel_editable_label_draw (GtkWidget *widget,
 	  gdk_cairo_region (cr, clip);
 	  cairo_clip (cr);
 
-	  state = GTK_STATE_FLAG_SELECTED;
-	  if (!gtk_widget_has_focus (widget))
-	    state = GTK_STATE_FLAG_ACTIVE;
+          state = gtk_widget_get_state_flags (widget);
+	  state |= GTK_STATE_FLAG_SELECTED;
 
           gtk_style_context_get_background_color (style, state, &background_color);
 	  gdk_cairo_set_source_rgba (cr, &background_color);



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