libxfce4panel could position panel plugin menus
ongardie at gmail.com
Fri Sep 28 16:21:46 CEST 2007
On 9/28/07, Nick Schermer <nickschermer at gmail.com> wrote:
> I don't see why there it is not just another GtkMenuPositionFunc.
> Because that's what you want, popup a menu... Or am I stupid or
These patches solved more problems than a GtkMenuPositionFunc would
have. Specifically, in no particular order:
1) Arrow directions
2) Positioning arbitrary widgets (see Alexandre's email)
3) Registering the menu ONLY when it's not already visible (see Harold's email)
4) Benefit from #3 even when the plugin wants its menu on the cursor
I won't agree that you're stupid, but I like to think that a
GtkMenuPositionFunc would have been insufficient and awkward to
include in the API. Also, it would have been more productive for you
to bring up a suggestion like this for discussion after my *first*
> If you want to calculate the arrow direction, fine, but don't do this
> in the same function.
I don't see why that's such a bad thing. After all, the logic to know
where the popup will be placed and the logic to know in which
direction it will be placed are identical. I'll admit it's strange to
have those functions return GtkArrowType to represent directions, but
it was the most convenient type to use.
More information about the Xfce4-dev