After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 653705 - GtkAssistant doesn't notice destroyed pages
GtkAssistant doesn't notice destroyed pages
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Widget: Other
3.1.x
Other Linux
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks: 652958
 
 
Reported: 2011-06-30 03:40 UTC by Matthew Barnes
Modified: 2011-07-09 21:57 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Proposed patch (7.20 KB, patch)
2011-06-30 03:44 UTC, Matthew Barnes
none Details | Review

Description Matthew Barnes 2011-06-30 03:40:32 UTC
When a page widget is destroyed via gtk_widget_destroy(), GtkAssistant doesn't notice because it's not listening for a "remove" signal from it's internal notebook.  Currently the only way to remove a page is by calling gtk_container_remove() on the GtkAssistant itself.

This is part of what's causing Evolution's account assistant to malfunction (bug 652958).
Comment 1 Matthew Barnes 2011-06-30 03:44:17 UTC
Created attachment 190984 [details] [review]
Proposed patch

This patch adds a "remove" signal handler on the internal notebook widget, which does the work of the remove_page() function.  It also changes GtkAssistant's own remove() method to simply call gtk_container_remove() on its notebook widget.
Comment 2 Matthew Barnes 2011-06-30 03:52:40 UTC
Oops, ignore the Makefile.am hunk in the patch.  That was to get past a build failure.
Comment 3 Matthias Clasen 2011-06-30 18:28:19 UTC
explicitly destroying child widgets without removing them from their containers is not something you are normally expected to do...
Comment 4 Matthias Clasen 2011-06-30 18:31:07 UTC
but yeah, this is a bit of a problem, due to the way we've muddled up the parent-child relationships here.
Comment 5 Matthew Barnes 2011-07-06 23:49:22 UTC
Any further thoughts on this?  Evolution's account assistant is still busted without this.  I could try to work around the problem in Evolution but this seems like the better long-term solution.
Comment 6 Matthias Clasen 2011-07-07 00:29:26 UTC
Sorry, I forgot. Please commit this, then.
Comment 7 Matthew Barnes 2011-07-09 21:57:43 UTC
Committed for GTK+ 3.1.9.

http://git.gnome.org/browse/gtk+/commit/?id=4d17ff973e8c289bf3186c70f68977356fd6b89e