Re: New 'GObject' as base for GtkObject?



> For example, in my server I have some places I've
> replaced the expensive casts to the native casts b/c
> they are called very frequently (e.g. in the GSourceFuncs functions).

	"GTK+/Gnome Application Development", page 143, 2nd paragraph:

[In reference to the GTK+ Object casting system, using a GtkButton as a
concrete example:]

"Instead of simply casting an object, you can use the GTK_BUTTON() macro.
If GTK_NO_CHECK_CASTS is defined, these macros are equivalent to simple
casts.  Otherwise, they retrieve the type of the object and compare it to
the type you're attempting to cast to."


	On your server, could you not have simply defined
GTK_NO_CHECK_CASTS to get the better performance?


--Derek




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