]> spindle.queued.net Git - midori/commitdiff
Actually remove history items with the Delete tool button
authorDale Whittaker <dayul@users.sf.net>
Mon, 15 Dec 2008 19:12:51 +0000 (20:12 +0100)
committerChristian Dywan <christian@twotoasts.de>
Mon, 15 Dec 2008 19:12:51 +0000 (20:12 +0100)
midori/midori-browser.c

index 6431e849527139040cf8c93323448fd367f09537..4bc3ec5cbf92fe6dba521f327694dc6371033d6d 100644 (file)
@@ -2491,6 +2491,7 @@ midori_browser_model_remove_item (GtkTreeModel* model,
 {
     GtkTreeIter child_iter;
     KatzeItem* child;
+    KatzeArray* parent;
     gint i, n;
 
     if (KATZE_IS_ARRAY (item))
@@ -2504,6 +2505,11 @@ midori_browser_model_remove_item (GtkTreeModel* model,
         while (gtk_tree_model_iter_nth_child (model, &child_iter, iter, 0))
             gtk_tree_store_remove (GTK_TREE_STORE (model), &child_iter);
     }
+    else
+    {
+        parent = katze_item_get_parent (item);
+        katze_array_remove_item (parent, item);
+    }
 
     gtk_tree_store_remove (GTK_TREE_STORE (model), iter);
     g_object_unref (item);