From f38c8425c362922508d4823f184f40b95d4fd1bf Mon Sep 17 00:00:00 2001
From: olpc user <olpc@xo-6d-61-0c.localdomain>
Date: Thu, 25 Oct 2012 09:11:30 +0000
Subject: [PATCH 2/4] EventIcon: able to dismiss Palette
Without this patch when tapping on an EventIcon
we do get a GDK_CROSSING_UNGRAB leave event when
the Palette is raised. Because of this the Invoker
does not know how to popdown the Palette when
you tap outside or when clicking on actions in the
Palette itself.
---
src/sugar3/graphics/icon.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/sugar3/graphics/icon.py b/src/sugar3/graphics/icon.py
index 5863118..2d66cf9 100644
a
|
b
|
class EventIcon(Gtk.EventBox): |
491 | 491 | Gtk.EventBox.__init__(self) |
492 | 492 | self.set_visible_window(False) |
493 | 493 | self.set_above_child(True) |
| 494 | self.add_events(Gdk.EventMask.BUTTON_PRESS_MASK | |
| 495 | Gdk.EventMask.TOUCH_MASK | |
| 496 | Gdk.EventMask.BUTTON_RELEASE_MASK) |
494 | 497 | for key, value in kwargs.iteritems(): |
495 | 498 | self.set_property(key, value) |
496 | 499 | |