GtkMenu question



Hello all,

In some situations I use a GtkMenu to present the user with a choice of 4 options.

The problem I have is that when the user clicks somewhere else the menu disappears.
What I would like is to either (in order of preference):
1. being able to tell that the user hasn't clicked on any item when the menu disappears (and make a default choice)
2. prevent the menu from disappearing unless the user has actually activated one of the menu items

I tried to implement 1 by connecting to the "hide" signal and setting some flag in the menu items handler, but it turns out the "hide" signal is sent before the one sent by activating a menu item so it doesn't work.

The alternative I'm looking at is to use a modal dialog but they tend to take a bit too much space and I'd rather use the pop-up menu.

Any ideas will be much appreciated,
Julien


Windows Live: Friends get your Flickr, Yelp, and Digg updates when they e-mail you.


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