From b77658247204d1ef31da4b3bc20c58cc3ad5c2a3 Mon Sep 17 00:00:00 2001 From: Gonzalo Odiard Date: Tue, 14 Jan 2014 20:43:22 +0000 Subject: Make consistent the tooltip of the show/hide tray button Fixes #4712. Signed-off-by: Gonzalo Odiard --- (limited to 'viewtoolbar.py') diff --git a/viewtoolbar.py b/viewtoolbar.py index 2008277..f65ae4f 100644 --- a/viewtoolbar.py +++ b/viewtoolbar.py @@ -110,7 +110,12 @@ class ViewToolbar(Gtk.Toolbar): def __tray_toggled_cb(self, button): if button.props.active: self._activity.tray.show() - self.traybutton.set_tooltip(_('Show Tray')) else: self._activity.tray.hide() + self.update_traybutton_tooltip() + + def update_traybutton_tooltip(self): + if not self.traybutton.props.active: + self.traybutton.set_tooltip(_('Show Tray')) + else: self.traybutton.set_tooltip(_('Hide Tray')) -- cgit v0.9.1