Re: how to do signal connect for clicking JUST ONE radio button?




Travis J.I. Corcoran said:

... but I need to figure out how to get a signal ONLY from the button
that has actually been clicked.

$radiobutton->signal_connect (toggled => sub {
       my $self = shift;
       if ($self->get_active) {
            # i've just been turned on, so i'm the one the
            # user just clicked.
       } else {
            # somebody else got clicked, and i've been turned off.
       }
});




-- 
muppet <scott at asofyet dot org>



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