Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/shell
diff options
context:
space:
mode:
authorMarco Pesenti Gritti <marco@localhost.localdomain>2006-09-12 11:21:18 (GMT)
committer Marco Pesenti Gritti <marco@localhost.localdomain>2006-09-12 11:21:18 (GMT)
commit53f7cc1f343e9f54bd61f92d434a9e700e7aa160 (patch)
tree63776f71947dff376f78c0593850480d2d7f577f /shell
parentd65e8b88e70350b24fd482946a47d6d418995f75 (diff)
Cleanup browser model service on destroy.
Remove the activity service even if the owner is gone.
Diffstat (limited to 'shell')
-rw-r--r--shell/PresenceService/PresenceService.py7
-rw-r--r--shell/home/MeshGroup.py3
2 files changed, 5 insertions, 5 deletions
diff --git a/shell/PresenceService/PresenceService.py b/shell/PresenceService/PresenceService.py
index 56b54a3..ae7f7e0 100644
--- a/shell/PresenceService/PresenceService.py
+++ b/shell/PresenceService/PresenceService.py
@@ -536,6 +536,9 @@ class PresenceService(object):
if not service:
return False
+ self._dbus_helper.ServiceDisappeared(service.object_path())
+ self._handle_remove_activity_service(service)
+
# Decompose service name if we can
(actid, buddy_name) = Service.decompose_service_name(full_name)
@@ -545,10 +548,8 @@ class PresenceService(object):
except KeyError:
pass
else:
- buddy.remove_service(service)
- self._dbus_helper.ServiceDisappeared(service.object_path())
- self._handle_remove_activity_service(service)
if not buddy.is_valid():
+ buddy.remove_service(service)
self._dbus_helper.BuddyDisappeared(buddy.object_path())
del self._buddies[buddy_name]
key = (service.get_full_name(), service.get_type())
diff --git a/shell/home/MeshGroup.py b/shell/home/MeshGroup.py
index bae483e..f7bc1c9 100644
--- a/shell/home/MeshGroup.py
+++ b/shell/home/MeshGroup.py
@@ -68,8 +68,7 @@ class MeshGroup(goocanvas.Group):
self._activities[item.get_id()] = item
- def _activity_disappeared_cb(self, activity):
- print 'remove'
+ def _activity_disappeared_cb(self, pservice, activity):
if self._activities.has_key(activity.get_id()):
self.remove_child(self._activities[activity.get_id()])
del self._activities[activity.get_id()]