Muncher & deleting Gtk-- windows
- From: Robert Knop <rknop panisse lbl gov>
- To: Havoc Pennington <rhpennin midway uchicago edu>
- cc: gtk-list redhat com
- Subject: Muncher & deleting Gtk-- windows
- Date: Thu, 27 Aug 1998 09:24:35 -0700 (PDT)
Putting in the idle handler which returns false, and which runs
immediately the next time the Gtk main loop is idle, pointed out that I'm
still having some trouble deleting Gtk-- windows.
If all that I have the "delete" callback (or the callback for whatever
"quit" button) for the window do is add the window's object to the Muncher
list, and all that Muncher does is delete the objects on its list, then
the window never actually closes... it stays there, which produces all
sorts of errors like :
** WARNING **: file widget.cc: line 265 (static int Gtk_Widget::leave_notify_event_callback(struct _GtkWidget *, struct_GdkEventCrossing *)): "obj"
** WARNING **: file widget.cc: line 166 (static int Gtk_Widget::event_callback(struct _GtkWidget *, union _GdkEvent *)): "obj"
when I move the mouse in and out of it.
The other option is have the delete event for the window object call
hide() before it adds itself to the Muncher list. In that case, the
window does go away, but there seem to be some residual events left over
which the main loop deals with _after_ it deals with the idle Muncher
task, because after the Muncher has munched the window, there are a
handful of ** WARNING ** errors.
Is there some way to "flush" all the events waiting for a given window and
all its children? Is there something besides just hide() I should call
for the window before I tell the Muncher to delete it at next idle?
(I think I didn't see this when I was using the "timeout" thing because
the timeout was just luckily letting the Gtk main loop deal with the
residual events before it called the timeout task.)
(The events waiting seem to be an unmap event, some leave notify events,
etc.)
Thanks,
-Rob
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
==== Rob Knop ===== rknop@lbl.gov ====== http://panisse.lbl.gov/~rknop ======
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]