[Glade-users] How to send user_data to callcack functions by glade only?



On Sat, 2009-04-11 at 10:18 +0800, donglongchao wrote:
Hi all,
I have a question using glade(3.4.5).
In the "signal" tab ,there is a item "user_data".I want to know how to
fill and what to fill to send the data I filled into the callback
function ,without using gtk_signal_connect(......) or something like
that,just and only use glade itself and
glade_xml_signal_autoconnect().
I do not know if i should define the data before I fill and send
it,and where should I define my data? global scope? statics one?I even
do not know if i could send data defined by myself.Remember just and
only use  glade itself and glade_xml_signal_autoconnect().
It is a simple question ,but confused me several days,will any one
help?Thanks.

If that really bugs you, autoconnect connects the signal handler
swapping the user_data with the widget's instance, like if you would use
g_signal_connect_swapped () in your code to connect to that signal.
Whatever you can use as your user data with autoconnect is limited to
the individual widgets from your glade file. I advise against using
glade_xml_signal_autoconnect () for anything but simplest projects. Use
glade_xml_signal_connect_data () instead, when you need to pass
allocated data around.


Wish you happy.
Dong




______________________________________________________________________
?????????????????
_______________________________________________
Glade-users maillist  -  Glade-users at lists.ximian.com
http://lists.ximian.com/mailman/listinfo/glade-users





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