[gtk+] GtkColorChooser: Fix selection of colors



commit 98801b07b4122996a8618d053a4eeed9b2843380
Author: Matthias Clasen <mclasen redhat com>
Date:   Wed Mar 20 22:17:14 2013 -0400

    GtkColorChooser: Fix selection of colors
    
    Prevent the new window dragging code from interfering with
    selection of colors on button release, by handling button
    presses we care about instead of letting them bubble up to
    the window.
    Partial fix for
    https://bugzilla.gnome.org/show_bug.cgi?id=695493

 gtk/gtkcolorswatch.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/gtk/gtkcolorswatch.c b/gtk/gtkcolorswatch.c
index c6081d7..8770f19 100644
--- a/gtk/gtkcolorswatch.c
+++ b/gtk/gtkcolorswatch.c
@@ -483,6 +483,10 @@ swatch_button_press (GtkWidget      *widget,
       g_signal_emit (swatch, signals[ACTIVATE], 0);
       return TRUE;
     }
+  else if (event->button == GDK_BUTTON_PRIMARY)
+    {
+      return TRUE;
+    }
 
   return FALSE;
 }


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