Re: [gtk-list] Re: Early difficulty



On Thu, 10 Dec 1998, Havoc Pennington wrote:

> 
> On Thu, 10 Dec 1998, Mihai Christodorescu wrote:
> > 
> > gtk_signal_emit_by_name( GTK_OBJECT( main_window ), "delete_event" );
> > 
> > The callback for the delete event for the main window gets called, but I
> > get a GDK segv:
> > 
> > Gdk-Message: 
> > ** ERROR **: sigsegv caught
> >
> 
> I would guess that you need more arguments to gtk_signal_emit_by_name() -
> in particular, I think delete_event returns a value, so you have to 
> pass the address of a location to store the returned value.

the delete_event reuires a GdkEvent structure and a return value, but besides
that, people should never call gtk_signal_emit* directly except for
GTK_RUN_ACTION signals.
mihai probably wants to either call gtk_widget_destroy() directly or invoke
his handler of delete_event directly which could fire up a save-before-close
dialog.

> 
> Havoc
> 

---
ciaoTJ



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