pidgin: 021e8f6b: Fix handling mouse events with menus.
sadrul at pidgin.im
sadrul at pidgin.im
Sat Sep 13 19:25:23 EDT 2008
-----------------------------------------------------------------
Revision: 021e8f6b481be8a2183a6c94379b98ef008cc534
Ancestor: 70f069dc39b8d304b9977924ff66e27882103fd4
Author: sadrul at pidgin.im
Date: 2008-09-13T23:31:33
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/021e8f6b481be8a2183a6c94379b98ef008cc534
Modified files:
finch/libgnt/gntmenu.c
ChangeLog:
Fix handling mouse events with menus.
The bug can cause seemingly unrelated crashes. Fixes #7071. Thanks to
Mark (queueRAM) for testing the fix.
-------------- next part --------------
============================================================
--- finch/libgnt/gntmenu.c 1ed44b777d746a7664c4481d917b96b6d2e7752d
+++ finch/libgnt/gntmenu.c 5991a201f76da038410c07dbce48bc06991264e5
@@ -399,9 +399,11 @@ gnt_menu_clicked(GntWidget *widget, GntM
static gboolean
gnt_menu_clicked(GntWidget *widget, GntMouseEvent event, int x, int y)
{
- if (!org_clicked || !org_clicked(widget, event, x, y) ||
- !GNT_MENU(widget)->type == GNT_MENU_TOPLEVEL)
- return FALSE;
+ if (GNT_MENU(widget)->type != GNT_MENU_POPUP)
+ return FALSE;
+
+ if (org_clicked && org_clicked(widget, event, x, y))
+ return TRUE;
gnt_widget_activate(widget);
return TRUE;
}
More information about the Commits
mailing list