[pygtk] Let's split it up...

Gian Mario Tagliaretti gianmt at gnome.org
Wed Jul 2 00:18:40 WST 2008


On Tue, Jul 1, 2008 at 4:09 PM, Alessandro Dentella <sandro a e-den.it> wrote:

> I want a CheckButton that doesn't react to "click".
>
> I thought to connect a handler to the signal "clicked" that just "return
> True" but it does not work. What's wrong?

you can try this way:

handler = c1.connect('clicked', on_clicked)
c1.handler_block(handler)

the signal won't be emitted, on the other hand if you also want the
graphics not to be updated use c1.set_sensitive(False)

to unblock the signal emission use:

c1.handler_unblock(handler)

cheers
-- 
Gian Mario Tagliaretti


More information about the pygtk mailing list