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-07-26 13:38:54 (GMT)
committer Marco Pesenti Gritti <marco@localhost.localdomain>2006-07-26 13:38:54 (GMT)
commitf5b1be244f1974178c2aae53144472cbcbccf712 (patch)
tree90cc112062c09cc2af77cdc3466f72c6584485e6 /shell
parentfd6367007ae4af085382bb778bfe8fe8a24f12fb (diff)
Get private chat to show, not working yet
Diffstat (limited to 'shell')
-rw-r--r--shell/PresenceService/Buddy.py5
-rw-r--r--shell/PresenceView.py4
2 files changed, 5 insertions, 4 deletions
diff --git a/shell/PresenceService/Buddy.py b/shell/PresenceService/Buddy.py
index 5a6c961..33eae9d 100644
--- a/shell/PresenceService/Buddy.py
+++ b/shell/PresenceService/Buddy.py
@@ -54,12 +54,12 @@ class BuddyDBusHelper(dbus.service.Object):
return icon
@dbus.service.method(BUDDY_DBUS_INTERFACE,
- in_signature="", out_signature="o")
+ in_signature="s", out_signature="o")
def getServiceOfType(self, stype):
service = self._parent.get_service_of_type(stype)
if not service:
raise NotFoundError("Not found")
- return service
+ return service.object_path()
@dbus.service.method(BUDDY_DBUS_INTERFACE,
in_signature="", out_signature="ao")
@@ -213,6 +213,7 @@ class Buddy(object):
for service in self._services.values():
if service.get_type() == stype and service.get_activity_id() == actid:
return service
+
if self._services.has_key(stype):
return self._services[stype]
return None
diff --git a/shell/PresenceView.py b/shell/PresenceView.py
index c9c2002..0539735 100644
--- a/shell/PresenceView.py
+++ b/shell/PresenceView.py
@@ -110,12 +110,12 @@ class PresenceView(gtk.VBox):
buddy = view.get_model().get_value(aniter, self._MODEL_COL_BUDDY)
if buddy:
chat_service = buddy.get_service_of_type(BuddyChat.SERVICE_TYPE)
+ print chat_service
if chat_service:
bus = dbus.SessionBus()
proxy_obj = bus.get_object('com.redhat.Sugar.Chat', '/com/redhat/Sugar/Chat')
chat_shell = dbus.Interface(proxy_obj, 'com.redhat.Sugar.ChatShell')
- serialized_service = Service.serialize(chat_service)
- chat_shell.open_chat(serialized_service)
+ chat_shell.open_chat(chat_service.object_path())
else:
print 'Could not find buddy chat'