Ensure to emit an activity changed signal when closing the last window. Fix #690.

This commit is contained in:
Marco Pesenti Gritti 2007-01-09 17:55:35 +01:00
parent 2136ac5046
commit 429a7ff970

View File

@ -71,6 +71,8 @@ class HomeModel(gobject.GObject):
def _window_closed_cb(self, screen, window): def _window_closed_cb(self, screen, window):
if window.get_window_type() == wnck.WINDOW_NORMAL: if window.get_window_type() == wnck.WINDOW_NORMAL:
self._remove_activity(window.get_xid()) self._remove_activity(window.get_xid())
if not self._activities:
self.emit('active-activity-changed', None)
def _get_activity_by_xid(self, xid): def _get_activity_by_xid(self, xid):
for act in self._activities.values(): for act in self._activities.values():