Re: delete-event of GtkWidget

Enrico TrÃger wrote:

Hm, I use -Wall for compiling with gcc. And this code doesn't produce a
g_signal_connect (dialog, "delete_event", G_CALLBACK(gtk_widget_hide),

And how could it? The gcc can't know which return type the definition
of the delete_event expects, can it?

Of course it can because it has a prototype in scope. The problem is
that the type is masked by the cast effected by G_CALLBACK. This is a
bit of a problem in general in gtk/GObject with all this casting back
and forth.

By the way, I always use -W -Wall -ansi -pedantic -O. This catches every
damn last catachable warning. (I think on a newer gcc version it's
-Wextra instead of just -W)


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