Merge lp:~seif/zeitgeist-datasources/fix-telepathy-code-style into lp:zeitgeist-datasources/0.8

Proposed by Seif Lotfy
Status: Merged
Merged at revision: 99
Proposed branch: lp:~seif/zeitgeist-datasources/fix-telepathy-code-style
Merge into: lp:zeitgeist-datasources/0.8
Diff against target: 63 lines (+13/-6)
2 files modified
telepathy/org.freedesktop.Telepathy.Client.Zeitgeist.service (+1/-1)
telepathy/zeitgeist-telepathy-observer.py (+12/-5)
To merge this branch: bzr merge lp:~seif/zeitgeist-datasources/fix-telepathy-code-style
Reviewer Review Type Date Requested Status
Morten Mjelva Approve
Review via email: mp+42758@code.launchpad.net

Description of the change

fix code style breakage

To post a comment you must log in.
101. By Seif Lotfy

fixed line removal

102. By Seif Lotfy

fixed line removal

Revision history for this message
Morten Mjelva (mortenmjelva) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'telepathy/org.freedesktop.Telepathy.Client.Zeitgeist.service'
2--- telepathy/org.freedesktop.Telepathy.Client.Zeitgeist.service 2010-11-08 15:48:49 +0000
3+++ telepathy/org.freedesktop.Telepathy.Client.Zeitgeist.service 2010-12-04 22:23:08 +0000
4@@ -1,3 +1,3 @@
5 [D-BUS Service]
6 Name=org.freedesktop.Telepathy.Client.Zeitgeist
7-Exec=/home/mortenmj/Software/zeitgeist-dataproviders/telepathy/zeitgeist-telepathy-observer.py
8+Exec=/home/seif/Projects/zeitgeist-dataproviders/telepathy/zeitgeist-telepathy-observer.py
9
10=== modified file 'telepathy/zeitgeist-telepathy-observer.py'
11--- telepathy/zeitgeist-telepathy-observer.py 2010-11-08 15:48:49 +0000
12+++ telepathy/zeitgeist-telepathy-observer.py 2010-12-04 22:23:08 +0000
13@@ -160,6 +160,7 @@
14 except KeyError:
15 self._target_alias = self._target_id
16
17+ self._connect_to_signals()
18 self._default_operations_finished()
19
20 def _get_requested_cb(self, req):
21@@ -188,15 +189,13 @@
22 # which depend on each other are executed in order.
23 def _channel_ready(self, channel):
24 self._target_id = self.properties[CHANNEL + '.TargetID']
25-
26+
27 # Get contact attribute interfaces
28 self[dbus.PROPERTIES_IFACE].Get(CHANNEL,
29 'Requested',
30 reply_handler=self._get_requested_cb,
31 error_handler=error)
32
33- self._connect_to_signals()
34-
35 # This is necessary so our signal isn't sent over D-Bus
36 def do_closed(self):
37 pass
38@@ -228,7 +227,7 @@
39 if self._channel_requested:
40 manifestation = unicode(Manifestation.USER_ACTIVITY)
41 else:
42- manifestation = unicode(Manifestation.WORLD_NOTIFICATION)
43+ manifestation = unicode(Manifestation.WORLD_ACTIVITY)
44
45 timestamp = int(time() * 1000)
46
47@@ -271,7 +270,15 @@
48 def _message_received_cb(self, identification, timestamp, sender, contenttype,
49 flags, content):
50 logging.debug("Message received")
51-
52+ if not self._subject:
53+ self._subject = [Subject.new_for_values(
54+ uri = self._target_id,
55+ interpretation = unicode(Interpretation.IMMESSAGE),
56+ manifestation = unicode(Manifestation.SOFTWARE_SERVICE),
57+ origin = self.account_path,
58+ mimetype = "text/plain",
59+ text = self._target_alias)]
60+
61 timestamp = timestamp * 1000
62
63 event = Event.new_for_values(

Subscribers

People subscribed via source and target branches