Hi all,
I'm porting some code which uses GtkFactoryItem to use GtkActionGroup and GtkUIManager. The basic menu strutures is fine but there is also some code which maps the keybindings into an array which is then searched to operate the correct function. The problem I am having is that the GCallback type which the Action group uses does not have any arguments whereas the GtkAction callback type has two arguments. How can I pass these arguments to the GCallback typed function or do I need to have a separate type to do this.
The code, where the functions are called is as follows, it is the ki->func.callback(); which is causing the problem. nocallback is of the type GtkFunction. In the previous version callback was of the GtkItemFactoryCallback1 but now it has to be GCallback
if ((ki = lookup_keybinding (si->prefs->the_keymap, event->keyval, event->state))) { if (ki->callback_action == -1) ki->func.nocallback (si); else ki->func.callback();
gtk_widget_draw (si->scorearea, NULL); }
Thanks in Advance
Adam
_______________________________________________ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list