[clocks] Enabled toggeling between single clock view and overview
- From: Seif Lotfy <seiflotfy src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [clocks] Enabled toggeling between single clock view and overview
- Date: Mon, 21 May 2012 14:31:51 +0000 (UTC)
commit f0e82badbc756f135d615b2cc50a8acd6ea08ade
Author: Seif Lotfy <seif lotfy collabora co uk>
Date: Sun May 20 22:55:38 2012 +0200
Enabled toggeling between single clock view and overview
main.py | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/main.py b/main.py
index fd38baa..8b058ce 100644
--- a/main.py
+++ b/main.py
@@ -75,6 +75,7 @@ class Window (Gtk.Window):
def _on_view_clock (self, button, index):
self.notebook.set_current_page (index)
+ self.toolbar._set_overview_toolbar ()
def _on_new_clicked (self, button):
self.show_all()
@@ -115,6 +116,7 @@ class ClocksToolbar (Gtk.Toolbar):
image = Gtk.Image ()
image.set_from_gicon (icon, Gtk.IconSize.BUTTON)
self.backButton.add(image)
+ self.backButton.connect ("clicked", lambda w: self.emit ("view-clock", self._buttonMap[self.last_widget]))
self.newButton.connect("clicked", self._on_new_clicked)
@@ -190,7 +192,7 @@ class ClocksToolbar (Gtk.Toolbar):
self.newButton.set_sensitive (False)
self.newButton.set_size_request(width, -1)
self.newButton.get_children()[0].hide()
-
+ self.last_widget = widget
self._busy = False
self.emit ("view-clock", self._buttonMap[widget])
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]