[10446] in The GTK GIMP ToolKit mailing list archive
[gtk-list] Re: A dumb question about gtk_widget_destroy().
daemon@ATHENA.MIT.EDU (Havoc Pennington)
Wed Nov 25 13:07:40 1998
Date: Wed, 25 Nov 1998 11:50:35 -0600 (CST)
From: Havoc Pennington <rhpennin@midway.uchicago.edu>
To: "Sergei O. Naoumov" <serge@physics.unc.edu>
cc: gtk-list@redhat.com
In-Reply-To: <199811251624.LAA23520@avarice.astro.unc.edu>
Resent-From: gtk-list@redhat.com
Reply-To: gtk-list@redhat.com
On Wed, 25 Nov 1998, Sergei O. Naoumov wrote:
> gtk_signal_connect_object (GTK_OBJECT (button), "clicked",
> GTK_SIGNAL_FUNC(gtk_widget_destroy),
> GTK_OBJECT (window));
>
> However, looking at gtkwidget.h, I see that gtk_widget_destroy() only has
> one argument, so the above piece of code should destroy the button
> itself, not the whole window. It does exactly that when I program it
> like this, but it works in testgtk.
>
connect_object does not pass the emitting object, only the user_data
object. You're probably confusing this with regular connect.
Havoc
--
To unsubscribe: mail -s unsubscribe gtk-list-request@redhat.com < /dev/null