Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/shell
diff options
context:
space:
mode:
authorTomeu Vizoso <tomeu@tomeuvizoso.net>2007-07-04 10:33:12 (GMT)
committer Tomeu Vizoso <tomeu@tomeuvizoso.net>2007-07-04 10:33:12 (GMT)
commit70e6d08f8d0fc385b8e7c539b09fced609b9c5a4 (patch)
tree5e420fc63ece0bc29b6b1c12a3cebeb050b84485 /shell
parent1796cbc0c7be1978628cce88e7686ce641ab32dd (diff)
Hide active palette if zoom level changes.
Diffstat (limited to 'shell')
-rw-r--r--shell/shellservice.py11
1 files changed, 10 insertions, 1 deletions
diff --git a/shell/shellservice.py b/shell/shellservice.py
index b4c96ff..dd5e224 100644
--- a/shell/shellservice.py
+++ b/shell/shellservice.py
@@ -56,11 +56,13 @@ class ShellService(dbus.service.Object):
self._home_model.connect('active-activity-changed',
self._cur_activity_changed_cb)
+ self._shell_model.connect('notify::zoom-level',
+ self._shell_model_notify_zoom_level_cb)
+
bus = dbus.SessionBus()
bus_name = dbus.service.BusName(_DBUS_SERVICE, bus=bus)
dbus.service.Object.__init__(self, bus_name, _DBUS_PATH)
-
@dbus.service.method(_DBUS_SHELL_IFACE,
in_signature="ss", out_signature="")
def NotifyLaunch(self, bundle_id, activity_id):
@@ -146,6 +148,10 @@ class ShellService(dbus.service.Object):
def CurrentActivityChanged(self, activity_id):
pass
+ @dbus.service.signal(_DBUS_SHELL_IFACE, signature="i")
+ def ZoomLevelChanged(self, new_level):
+ pass
+
def _cur_activity_changed_cb(self, owner, new_activity):
new_id = ""
if new_activity:
@@ -153,6 +159,9 @@ class ShellService(dbus.service.Object):
if new_id:
self.CurrentActivityChanged(new_id)
+ def _shell_model_notify_zoom_level_cb(self, shell_model, pspec):
+ self.ZoomLevelChanged(shell_model.props.zoom_level)
+
def _bundle_to_dict(self, bundle):
return {'name': bundle.get_name(),
'icon': bundle.get_icon(),