Re: Signal attach to GtkOptionMenu
- From: Paolo Molaro <lupus ximian com>
- To: gtk-perl-list gnome org
- Subject: Re: Signal attach to GtkOptionMenu
- Date: Wed, 4 Apr 2001 15:16:24 +0200
On 04/01/01 dLux wrote:
/--- On Wed, Mar 21, 2001 at 07:43:03PM +0100, Paolo Molaro wrote:
| > I have tried to attach a "clicked" signal handler to a
| > GtkOptionMenu object, but it does not seem to be called. Enter
| > and
| > Leave signal handlers works fine.
|
| It's quite possible the clicked signal doesn't get emitted at
| all for the optionmenu widget: it is a button, but works quite
| differently. Maybe the pressed signal is emitted, or you may
| try connecting to the button-press-event...
\---
I have got a problem with this: If I attach something to the
button-press, then it is emitted when the popup window created. I
need to attach signal to the event when the selection is chosen, so
the popup window is closed. Is there any way to do it with glade?
Oh, that's an entirely different problem.
$menu = $optionmenu->get_menu;
$menu->signal_connec('selection-done', \&handler);
Should do what you need, but I haven't tested it.
lupus
--
-----------------------------------------------------------------
lupus debian org debian/rules
lupus ximian com Monkeys do it better
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]