Re: Panel applet: Menu missing + problems debugging



Asked this question on gnome-list gnome org, but no response yet, so I thought I might try here:

I have developed an GNOME 2 panel applet (or rather, ported it from GNOME 1) that works mostly fine, but the right-click menu isn't displayed. The code I'm using to add the menu is included below (there will actually be more buttons, but I'm trying the simple case first.) Can anyone find anything wrong with it? Also the main reason why I can't get it to work is that I don't know how to debug a panel applet. What can I do if I want to display debug output from it, or run it through a debugger?
[ ... ]

I figured it out eventually. First of all, the XML tree presented wasn't quite correct - apparently, "<Root> ... <popups>" shouldn't be included in this case. I tried with and without them, though, and the menu failed to be popped up in both cases. However, the menu failure turned out to be a result of the way I'd set up my widget tree. The applet contained a pixmap within a button - I don't remember why, but perhaps this was necessary in GNOME-1. Apparently, the button caused mouse clicks to be mapped the wrong way or something so that the popup would fail. I have now changed the layout so that the pixmap is added directly to the applet widget, and the menu shows up just fine now. The callbacks still don't do what I expected, though - I *really* need the debug support to be able to figure out what is going on.

- Toralf



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