Re: radioitem
- From: Torsten Schoenfeld <kaffeetisch gmx de>
- To: gtk-perl-list gnome org
- Subject: Re: radioitem
- Date: Tue, 19 Jul 2005 15:28:41 +0200
On Tue, 2005-07-19 at 20:05 +0700, Beast wrote:
---
children => [
'Radio One' => {
callback => sub { print "Radio ONE\n";},
callback_action => 10,
item_type => '<RadioItem>',
groupid => 1
},
'Radio Two' => {
callback => sub { print "Radio Two\n";},
callback_action => 11,
item_type => '<RadioItem>',
groupid => 1
},
---
First of all, the GnomeUIInfo stuff is ugly and deprecated. Take a look
at Glade and/or GtkAction[1].
It will call both One and Two when togle the selection.
That's normal since both buttons got toggled after all. In the
callbacks, check $radio->get_active ($radio is the first argument to the
callbacks) to find out if your button is on or off.
--
Bye,
-Torsten
[1] http://developer.gnome.org/doc/API/2.0/gtk/Actions.html
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]