Howdy all.. I've been trying to rewrite my python/gnome1 -based applets in python/gnome2 (somewhat forced into it because of the recent debian/unstable gnome2 switch). One of the more significant changes in gtk2/gnome2 that shows up in panel applets is that right-clicks on top of GtkButtons no longer result in the applet's menu appearing. I don't know if this is because GtkButtons consume the button2 and button3 events instead of passing them up to their containers (they do, but from what I can tell they did in gtk1.2 as well) or because the new bonobo-based libpanel-applet system does something different than the old applet-widget scheme (it does, but I don't know if it is not implementing an old workaround or if something else changed).
The net result is that, in the applets I write that contain buttons, it is difficult to get to the applet's context menu (to configure or remove the applet). If the applet is all button, it is impossible. Several of standard Gnome applets (in gnome-applets-2.0.3), drivemount and mini-commander in particular, have a hack to work around this. The hack adds a signal handler to the GtkButton which catches button2/button3 and uses gtk_propagate_event() to send the event off to the applet as a whole, which responds by putting up the context menu. button1 events are ignored/refused; the signal handler returns FALSE to let the event go to the GtkButton as usual. In lieu of seeing GtkButtons changed to let button2/button3 events get passed along to their containers, I wanted to implement this same hack in my python applets. But gtk_propagate_event() is missing from the python binding, as it is listed in an %ignore clause in the gtk.override file. Any idea why there is no binding for this function? Or how hard it would be to add one? If there's a better workaround for this problem I'd love to hear it, but I suspect a real fix would involve changes to gtk that aren't going to happen any time soon. thanks, -Brian _______________________________________________ pygtk mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/