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

RE: Please help me



	I just found in section 2.4 of the tutorial, that it is indeed 
	(GtkWidget *widget, GdkEvent *event, gpointer callback_data)
	for the button_pressed_event.

	The one thing (and probably the only thing :) I liked about 
	Motif more than GTK, is the callback function parameters.
	They are all the SAME! 
	I know that in some cases you need to have special
	cases to handle calling gtk functions with signals, 
	but that is what "gtk_signal_connect_object" is for.

	Motif always had three parameters.
	A pointer to the widget performing the callback.
	A pointer to a structure with that widgets info (including 
	events)
	And a pointer to the callback_data.

	Most cases, I only want that callback data.
	I find that I searching the tutorial alot to figure out
	which parameter that data goes into.
	When using CList, the parameters are even more
	important.  
	It would have been nice to follow Motif in this aspect,
	(since it is too late to turn back now). Because
	you can always add a new parameter for the
	widget by updating the widget structure.

	Like I asked before, Is there some mapping of the
	signals to widgets and the parameters they use.
	This would be a good appendix for the tutorial.
	If I get some time, I'm willing to write it.
	But I would like to know first, if it was already done.

	Thanks again.
	 Steve.


> Someone correct me if I'm wrong, but  I believe
> button_pressed_event signals call a function with three parameters.
> GtkWidget *, GdkEvent *, gpointer data.
> 
> Your "data" parameter in MakeMove is actualy the "event" 
> and not the data you passed.
> 
> There should be a section in the tutorial that maps the
> events and the parameters used for ALL types of signals
> used with the related functions.
> If there already is, then please let me know where.
> ie. "button_pressed_event"  -> (GtkWidget *, GdkEvent *, gpointer)
> "clicked" -> (GtkWidget *, gpointer)
> etc.
> Thank you!
> 
> > What am I doing wrong?!
> > Greetings, Norbert de Jonge
> > 
> > ----------------------------------------------------------------
> > Get your free email from AltaVista at http://altavista.iname.com <<
> File:
> > text, base64 encoded >> 
> 
> 
> -- 
>          To unsubscribe: mail gtk-app-devel-list-request@redhat.com with 
>                        "unsubscribe" as the Subject.
> 
> 	Mailing list concerns should be mailed to <listmaster@redhat.com>



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