[Glade-users] function pointers and signals
- From: tvb at gnome.org (Tristan Van Berkom)
- Subject: [Glade-users] function pointers and signals
- Date: Sun, 17 Dec 2006 13:29:37 -0500
antonio giulio wrote:
Hi,
using glade-GUI I have added a signal for a button. In "Object" field
I want to insert a function-pointer for a generic function:
void on_button_clicked(GtkButton * button, gpointer user_data)
{
...
void (* func) (gint) = user_data;
...
}
but in run-time I got "user_data = 0x0".
Is it possible past in Glade-GUI a function pointer?
No currently its not possible to get a function
pointer as user-data when defining the signal
in glade, it could be possible to resolve a user
defined string using dlsym(), effectively passing
any globally visible symbol's pointer into the
user_data argument.
This patch to libglade already does it:
http://bugzilla.gnome.org/show_bug.cgi?id=161903
But the future of glade is in the builder, so
I'd suggest you make an RFE for that on this bug:
http://bugzilla.gnome.org/show_bug.cgi?id=172535
(maybe it will help to grease the wheel :D)
Cheers,
-Tristan
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]