pyGTK identify a button

Tracubik affdfsdfdsfsd at b.com
Wed May 25 04:51:50 EDT 2011


On 25/05/2011 10:44, Claudiu Nicolaie CISMARU wrote:
>> the two button are connected (when clicked) to infoButton(self,
>> widget,
>> data=None)
>
>  From documentation:
> handler_id = object.connect(name, func, func_data)
>
> So:
>
> button1.connect(when is pressed, your_function, 1)
> button2.connect(when is pressed, your_function, 2)
> (This code is conception, I don't really know how is done in GTK).

thanks but, as i've sayed before, i can't use func_data 'cause i don't 
know how to set it on glade3.8, that is the program i use to create the 
GUI.
Anyway, i think this is the only way to identify the button :-/



More information about the Python-list mailing list