]> spindle.queued.net Git - midori/commitdiff
Don't destroy inspector window that will be re-used
authorAndré Stösel <andre@stoesel.de>
Tue, 19 Apr 2011 21:21:31 +0000 (23:21 +0200)
committerChristian Dywan <christian@twotoasts.de>
Tue, 19 Apr 2011 21:21:31 +0000 (23:21 +0200)
midori/midori-browser.c
midori/midori-view.c

index c557179a16677b1e67532ac6ccb0fe87719e6c21..8958cbc807aab8aa196085ad8a11ca2b1f4d4905 100644 (file)
@@ -1262,9 +1262,11 @@ midori_view_detach_inspector_cb (GtkWidget*     view,
                                  MidoriBrowser* browser)
 {
     GtkWidget* scrolled = gtk_widget_get_parent (GTK_WIDGET (inspector_view));
+    GtkWidget* paned = gtk_widget_get_parent (scrolled);
     browser->inspector_view = gtk_viewport_new (NULL, NULL);
     gtk_container_remove (GTK_CONTAINER (scrolled), GTK_WIDGET (inspector_view));
     gtk_container_add (GTK_CONTAINER (scrolled), browser->inspector_view);
+    gtk_widget_hide (paned);
 }
 
 static void
index 6de6f74b0a54a26773741fc2a4c2e7bf2a550149..753713564cd6263933c5211e824f495289052805 100644 (file)
@@ -3736,7 +3736,7 @@ midori_view_web_inspector_close_window_cb (gpointer    inspector,
     GtkWidget* scrolled = gtk_widget_get_parent (GTK_WIDGET (inspector_view));
     if (!scrolled)
         return FALSE;
-    gtk_widget_destroy (gtk_widget_get_parent (scrolled));
+    gtk_widget_hide (gtk_widget_get_parent (scrolled));
     return TRUE;
 }