summaryrefslogtreecommitdiff
path: root/src/ntl-index-panel.c
diff options
context:
space:
mode:
authorRamiro Estrugo <ramiro@src.gnome.org>2000-05-26 20:48:04 +0000
committerRamiro Estrugo <ramiro@src.gnome.org>2000-05-26 20:48:04 +0000
commitde44485366db09404cc59f0e193bd03b3a737300 (patch)
tree09c48caf4c94afd02504a8a5a336b3d4b50b9f42 /src/ntl-index-panel.c
parent56afae5d489131c23a738f0ccfe9bc23b94e3bdb (diff)
downloadnautilus-de44485366db09404cc59f0e193bd03b3a737300.tar.gz
Remove the tab associated with meta view as well. Add a warning for the
* src/ntl-index-panel.c: (nautilus_index_panel_remove_meta_view): Remove the tab associated with meta view as well. Add a warning for the case when the page_num is bogus. Perhaps this should be an assertion. But at least this way it wont fail silently.
Diffstat (limited to 'src/ntl-index-panel.c')
-rw-r--r--src/ntl-index-panel.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/ntl-index-panel.c b/src/ntl-index-panel.c
index c73380b69..d76039ea0 100644
--- a/src/ntl-index-panel.c
+++ b/src/ntl-index-panel.c
@@ -497,15 +497,24 @@ nautilus_index_panel_remove_meta_view (NautilusIndexPanel *index_panel,
NautilusViewFrame *meta_view)
{
int page_num;
+ char *description;
page_num = gtk_notebook_page_num (GTK_NOTEBOOK (index_panel->details->notebook),
GTK_WIDGET (meta_view));
if (page_num < 0) {
+ g_warning ("nautilus_index_panel_remove_meta_view: page_num '%d' for meta_view is bogus.\n", page_num);
return;
}
gtk_notebook_remove_page (GTK_NOTEBOOK (index_panel->details->notebook),
page_num);
+
+ description = nautilus_view_frame_get_label (meta_view);
+
+ /* Remove the tab associated with this meta view */
+ nautilus_index_tabs_remove_view (index_panel->details->index_tabs, description);
+
+ g_free (description);
}
/* utility to activate the metaview corresponding to the passed in index */