[Xfce4-commits] <midori:master> Only show bookmarkbar if we have bookmarks at all

Christian Dywan noreply at xfce.org
Sun Oct 31 21:36:03 CET 2010


Updating branch refs/heads/master
         to f9559b7d27b72cb4396026c533c3c2338e2afb7a (commit)
       from 560ad66d48760193a0ed2eee31c145094ffc5bfe (commit)

commit f9559b7d27b72cb4396026c533c3c2338e2afb7a
Author: Christian Dywan <christian at twotoasts.de>
Date:   Sun Oct 31 21:27:22 2010 +0100

    Only show bookmarkbar if we have bookmarks at all

 midori/midori-browser.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/midori/midori-browser.c b/midori/midori-browser.c
index 503f42b..62318de 100644
--- a/midori/midori-browser.c
+++ b/midori/midori-browser.c
@@ -945,7 +945,8 @@ midori_browser_edit_bookmark_dialog_new (MidoriBrowser* browser,
         }
 
         if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (check_toolbar)))
-            if (!gtk_widget_get_visible (browser->bookmarkbar))
+            if (!gtk_widget_get_visible (browser->bookmarkbar)
+             && browser->bookmarks != NULL)
                 _action_set_active (browser, "Bookmarkbar", TRUE);
         g_free (selected);
         return_status = TRUE;
@@ -6198,7 +6199,8 @@ _midori_browser_update_settings (MidoriBrowser* browser)
 
     _action_set_active (browser, "Menubar", show_menubar);
     _action_set_active (browser, "Navigationbar", browser->show_navigationbar);
-    _action_set_active (browser, "Bookmarkbar", show_bookmarkbar);
+    _action_set_active (browser, "Bookmarkbar", show_bookmarkbar
+                                             && browser->bookmarks != NULL);
     _action_set_active (browser, "Panel", show_panel);
     #if WEBKIT_CHECK_VERSION (1, 1, 3)
     _action_set_active (browser, "Transferbar", show_transferbar);



More information about the Xfce4-commits mailing list