Merge lp:~zeitgeist/unity-lens-applications/fix-1196822-port-to-libzeitgeist2 into lp:unity-lens-applications

Status: Needs review
Proposed branch: lp:~zeitgeist/unity-lens-applications/fix-1196822-port-to-libzeitgeist2
Merge into: lp:unity-lens-applications
Diff against target: 104 lines (+15/-15)
4 files modified
configure.ac (+1/-1)
debian/control (+1/-1)
src/Makefile.am (+1/-1)
src/daemon.vala (+12/-12)
To merge this branch: bzr merge lp:~zeitgeist/unity-lens-applications/fix-1196822-port-to-libzeitgeist2
Reviewer Review Type Date Requested Status
Marco Trevisan (Treviño) 2013-07-02 Needs Fixing on 2013-09-11
PS Jenkins bot (community) continuous-integration Needs Fixing on 2013-09-11
Review via email: mp+172475@code.launchpad.net

Commit message

Port unity-lens-applications to libzeitgeist2

Description of the change

Fixes LP #1196822 by porting unity-lens-applications to libzeitgeist2 and updated debian/control with proper build-dep

The Ubuntu Bug is #1197569

(PS - Signed contributor's agreement)

To post a comment you must log in.
Marco Trevisan (Treviño) (3v1n0) wrote :

Everything looks fine to me, thanks!

review: Approve
Marco Trevisan (Treviño) (3v1n0) wrote :

This doesn't merge cleanly with trunk, can you please update it?

review: Needs Fixing

Unmerged revisions

350. By Manish Sinha (मनीष सिन्हा) on 2013-07-02

Updated debian/control to build-dep on libzeitgeist2

349. By Manish Sinha (मनीष सिन्हा) on 2013-07-02

Fixes LP #1196822 by porting unity-lens-applications to libzeitgeist2

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'configure.ac'
2--- configure.ac 2013-05-16 21:13:36 +0000
3+++ configure.ac 2013-07-02 07:32:32 +0000
4@@ -74,7 +74,7 @@
5 gio-unix-2.0 >= $GLIB_REQUIRED
6 gee-1.0
7 dee-1.0 >= 0.5.16
8- zeitgeist-1.0 >= 0.3.8
9+ zeitgeist-2.0 >= 0.9.12
10 libcolumbus0 >= 0.4.0
11 unity >= 7.0.0
12 unity-protocol-private
13
14=== modified file 'debian/control'
15--- debian/control 2013-06-08 21:35:34 +0000
16+++ debian/control 2013-07-02 07:32:32 +0000
17@@ -10,7 +10,7 @@
18 libglib2.0-dev (>= 2.27),
19 libgee-dev,
20 libdee-dev (>= 0.5.16),
21- libzeitgeist-dev (>= 0.3.8),
22+ libzeitgeist-2.0-dev (>= 0.9.12),
23 libunity-dev (>= 7.0.0),
24 libgnome-menu-3-dev,
25 dh-autoreconf,
26
27=== modified file 'src/Makefile.am'
28--- src/Makefile.am 2013-05-16 11:37:05 +0000
29+++ src/Makefile.am 2013-07-02 07:32:32 +0000
30@@ -33,7 +33,7 @@
31 --pkg gio-2.0 \
32 --pkg gio-unix-2.0 \
33 --pkg dee-1.0 \
34- --pkg zeitgeist-1.0 \
35+ --pkg zeitgeist-2.0 \
36 --pkg unity \
37 --pkg unity-protocol \
38 --pkg gee-1.0 \
39
40=== modified file 'src/daemon.vala'
41--- src/daemon.vala 2013-07-01 12:17:01 +0000
42+++ src/daemon.vala 2013-07-02 07:32:32 +0000
43@@ -101,7 +101,7 @@
44 private Unity.LauncherFavorites favorite_apps;
45 private AppWatcher app_watcher;
46
47- private PtrArray zg_templates;
48+ private GenericArray<Event> zg_templates;
49
50 /* Gnome menu structure - also used to check whether apps are installed */
51 private uint app_menu_changed_reindex_timeout = 0;
52@@ -467,13 +467,13 @@
53 private void populate_zg_templates ()
54 {
55 /* Create a template that activation of applications */
56- zg_templates = new PtrArray.sized(1);
57- var ev = new Zeitgeist.Event.full (ZG_ACCESS_EVENT, ZG_USER_ACTIVITY, "",
58- new Subject.full ("application*",
59- "", //NFO_SOFTWARE,
60- "",
61- "", "", "", ""));
62- zg_templates.add ((ev as GLib.Object).ref());
63+ zg_templates = new GenericArray<Event>();
64+ var ev = new Zeitgeist.Event.full (ZG.ACCESS_EVENT, ZG.USER_ACTIVITY, "","");
65+ ev.add_subject(new Subject.full ("application*",
66+ "", //NFO.SOFTWARE,
67+ "",
68+ "", "", "", ""));
69+ zg_templates.add (ev);
70 }
71
72 private void mark_dirty ()
73@@ -487,7 +487,7 @@
74 try
75 {
76 // simulate a kind of frecency
77- var end_ts = Timestamp.now ();
78+ var end_ts = Timestamp.from_now ();
79 var start_ts = end_ts - Timestamp.WEEK * 3;
80 var rs = yield log.find_events (new TimeRange (start_ts, end_ts),
81 zg_templates,
82@@ -499,11 +499,11 @@
83 // most popular apps must have high value, so unknown apps (where
84 // popularity_map[app] == 0 aren't considered super popular
85 int relevancy = 256;
86- foreach (unowned Event event in rs)
87+ foreach (Event event in rs)
88 {
89 for (int i = 0; i < event.num_subjects (); i++)
90 {
91- unowned string uri = event.get_subject (i).get_uri ();
92+ string uri = event.get_subject (i).uri;
93 if (uri == null) continue;
94 popularity_map[uri] = relevancy;
95 }
96@@ -1846,7 +1846,7 @@
97 {
98 string? app_uri = null;
99 if (ev.num_subjects () > 0)
100- app_uri = ev.get_subject (0).get_uri ();
101+ app_uri = ev.get_subject (0).uri;
102
103 if (app_uri == null)
104 {

Subscribers

People subscribed via source and target branches