Re: delete-event of GtkWidget
- From: "Dan H." <dunno stoptrick com>
- To: Enrico TrÃger <enrico troeger uvena de>
- Cc: gtk-app-devel-list gnome org
- Subject: Re: delete-event of GtkWidget
- Date: Mon, 22 Jan 2007 14:10:09 +0100
Enrico TrÃger wrote:
Hm, I use -Wall for compiling with gcc. And this code doesn't produce a
warning:
g_signal_connect (dialog, "delete_event", G_CALLBACK(gtk_widget_hide),
NULL);
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)
--Dan
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]