[Xfce4-commits] <midori:master> Hide forward tool button when it's insensitive
Christian Dywan
noreply at xfce.org
Sat Jul 28 13:44:01 CEST 2012
Updating branch refs/heads/master
to 0f525a99fd81bd293f82c41083d85dea6cabba0c (commit)
from dfec1666913eadfc13979402284714030a2df178 (commit)
commit 0f525a99fd81bd293f82c41083d85dea6cabba0c
Author: Christian Dywan <christian at twotoasts.de>
Date: Sat Jul 28 13:41:33 2012 +0200
Hide forward tool button when it's insensitive
Fixes: https://bugs.launchpad.net/midori/+bug/823736
midori/midori-browser.c | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/midori/midori-browser.c b/midori/midori-browser.c
index 4e091a4..b103d79 100644
--- a/midori/midori-browser.c
+++ b/midori/midori-browser.c
@@ -316,11 +316,16 @@ _midori_browser_update_interface (MidoriBrowser* browser,
gboolean loading = midori_view_get_load_status (view) != MIDORI_LOAD_FINISHED;
gboolean can_reload = midori_view_can_reload (view);
GtkAction* action;
+ GSList* proxies;
_action_set_sensitive (browser, "Reload", can_reload);
_action_set_sensitive (browser, "Stop", can_reload && loading);
_action_set_sensitive (browser, "Back", midori_view_can_go_back (view));
_action_set_sensitive (browser, "Forward", midori_view_can_go_forward (view));
+ proxies = gtk_action_get_proxies (_action_by_name (browser, "Forward"));
+ for (; proxies != NULL; proxies = g_slist_next (proxies))
+ if (GTK_IS_TOOL_ITEM (proxies->data))
+ gtk_widget_set_visible (proxies->data, midori_view_can_go_forward (view));
_action_set_sensitive (browser, "Previous",
midori_view_get_previous_page (view) != NULL);
_action_set_sensitive (browser, "Next",
More information about the Xfce4-commits
mailing list