diff options
author | Marco Pesenti Gritti <marco@localhost.localdomain> | 2008-06-07 10:10:22 (GMT) |
---|---|---|
committer | Marco Pesenti Gritti <marco@localhost.localdomain> | 2008-06-07 10:10:22 (GMT) |
commit | e623294eaab90af4549e730c1bf038ac29a2682b (patch) | |
tree | cb6e14fcf32bb4ec8e87449d94863f9842b3f7dc /src/view | |
parent | 438e2df989ced05dbeecba8fc45f166342ab2545 (diff) |
Shell service notify launch status directly to the model.
The shell view listen to the model.
Diffstat (limited to 'src/view')
-rw-r--r-- | src/view/Shell.py | 20 |
1 files changed, 7 insertions, 13 deletions
diff --git a/src/view/Shell.py b/src/view/Shell.py index 9fdd928..41f83a3 100644 --- a/src/view/Shell.py +++ b/src/view/Shell.py @@ -66,7 +66,8 @@ class Shell(gobject.GObject): self._home_window.show() home_model = self._model.get_home() - home_model.connect('launch-completed', self._launch_completed_cb) + home_model.connect('launch-started', self.__launch_started_cb) + home_model.connect('launch-completed', self.__launch_completed_cb) home_model.connect('activity-removed', self._activity_removed_cb) home_model.connect('active-activity-changed', self._active_activity_changed_cb) @@ -92,7 +93,11 @@ class Shell(gobject.GObject): if registry.get_activity('org.laptop.JournalActivity'): self.start_activity('org.laptop.JournalActivity') - def _launch_completed_cb(self, home_model, home_activity): + def __launch_started_cb(self, home_model, home_activity): + # Zoom to Home for launch feedback + self.set_zoom_level(shellmodel.ShellModel.ZOOM_HOME) + + def __launch_completed_cb(self, home_model, home_activity): activity_host = ActivityHost(home_activity) self._hosts[activity_host.get_xid()] = activity_host if home_activity.get_type() in self._activities_starting: @@ -141,17 +146,6 @@ class Shell(gobject.GObject): handle = ActivityHandle(activity_id) activityfactory.create(bundle_id, handle) - def notify_launch(self, bundle_id, activity_id): - # Zoom to Home for launch feedback - self.set_zoom_level(shellmodel.ShellModel.ZOOM_HOME) - - home_model = self._model.get_home() - home_model.notify_activity_launch(activity_id, bundle_id) - - def notify_launch_failure(self, activity_id): - home_model = self._model.get_home() - home_model.notify_activity_launch_failed(activity_id) - def start_activity(self, activity_type): if activity_type in self._activities_starting: logging.debug("This activity is still launching.") |