Merge lp:~ssweeny/savilerow/unity-scope-selfservicebundles-api050 into lp:~savilerow-team/savilerow/unity-scope-selfservicebundles

Proposed by Scott Sweeny
Status: Merged
Merged at revision: 11
Proposed branch: lp:~ssweeny/savilerow/unity-scope-selfservicebundles-api050
Merge into: lp:~savilerow-team/savilerow/unity-scope-selfservicebundles
Diff against target: 196 lines (+27/-25)
7 files modified
CMakeLists.txt (+1/-1)
debian/changelog (+6/-0)
debian/control (+1/-1)
src/SelfServiceBundlesQuery.cpp (+3/-4)
src/SelfServiceBundlesQuery.h (+3/-4)
src/SelfServiceBundlesScope.cpp (+8/-10)
src/SelfServiceBundlesScope.h (+5/-5)
To merge this branch: bzr merge lp:~ssweeny/savilerow/unity-scope-selfservicebundles-api050
Reviewer Review Type Date Requested Status
Chris Wayne (community) Approve
Review via email: mp+224839@code.launchpad.net

Description of the change

Updates to align with scopes API 0.5.0. Also fixed some comment headers erroneously copied from another project. No functional changes.

Tested on a Nexus 4 running the latest devel-proposed image.

To post a comment you must log in.
Revision history for this message
Chris Wayne (cwayne) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'CMakeLists.txt'
2--- CMakeLists.txt 2014-03-27 03:43:12 +0000
3+++ CMakeLists.txt 2014-06-27 14:07:53 +0000
4@@ -12,7 +12,7 @@
5 FIND_PACKAGE(Qt5Test REQUIRED)
6 FIND_PACKAGE(PkgConfig REQUIRED)
7 PKG_CHECK_MODULES(UUID REQUIRED uuid>=2.20.0)
8-PKG_CHECK_MODULES(SCOPESLIB REQUIRED libunity-scopes>=0.3.0)
9+PKG_CHECK_MODULES(SCOPESLIB REQUIRED libunity-scopes>=0.5.0)
10
11 IF(${INTLTOOL_MERGE} MATCHES "INTLTOOL_MERGE-NOTFOUND")
12 MESSAGE(FATAL_ERROR "xxx")
13
14=== modified file 'debian/changelog'
15--- debian/changelog 2014-06-04 13:57:52 +0000
16+++ debian/changelog 2014-06-27 14:07:53 +0000
17@@ -1,3 +1,9 @@
18+unity-scope-selfservicebundles (0.4) UNRELEASED; urgency=medium
19+
20+ * Update for Scopes API version 0.5.0
21+
22+ -- Scott Sweeny <scott.sweeny@canonical.com> Tue, 24 Jun 2014 18:18:40 -0400
23+
24 unity-scope-selfservicebundles (0.3) utopic; urgency=medium
25
26 * Don't use empty URLs for results (LP: #1322337)
27
28=== modified file 'debian/control'
29--- debian/control 2014-01-31 19:55:50 +0000
30+++ debian/control 2014-06-27 14:07:53 +0000
31@@ -4,7 +4,7 @@
32 Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
33 Build-Depends: cmake,
34 debhelper (>= 9),
35- libunity-scopes-dev (>= 0.2.0~),
36+ libunity-scopes-dev (>= 0.5.0~),
37 uuid-dev,
38 gettext,
39 intltool,
40
41=== modified file 'src/SelfServiceBundlesQuery.cpp'
42--- src/SelfServiceBundlesQuery.cpp 2014-03-26 16:50:14 +0000
43+++ src/SelfServiceBundlesQuery.cpp 2014-06-27 14:07:53 +0000
44@@ -33,10 +33,9 @@
45 using namespace std;
46 using namespace unity::scopes;
47
48-SelfServiceBundlesQuery::SelfServiceBundlesQuery(CannedQuery const& query, QStringList const& scopes, QString const& locale)
49- : SearchQueryBase(),
50- query_(query),
51- scopes_(scopes)
52+SelfServiceBundlesQuery::SelfServiceBundlesQuery(CannedQuery const& query, SearchMetadata const& metadata)
53+ : SearchQueryBase(query, metadata),
54+ query_(query)
55 {
56 }
57
58
59=== modified file 'src/SelfServiceBundlesQuery.h'
60--- src/SelfServiceBundlesQuery.h 2014-03-26 16:50:14 +0000
61+++ src/SelfServiceBundlesQuery.h 2014-06-27 14:07:53 +0000
62@@ -1,5 +1,5 @@
63 /*
64- * Copyright (C) 2013 Canonical, Ltd.
65+ * Copyright (C) 2014 Canonical, Ltd.
66 *
67 * This program is free software: you can redistribute it and/or modify it
68 * under the terms of the GNU General Public License version 3, as published
69@@ -13,7 +13,7 @@
70 * You should have received a copy of the GNU General Public License along
71 * with this program. If not, see <http://www.gnu.org/licenses/>.
72 *
73- * Author: Pawel Stolowski <pawel.stolowski@canonical.com>
74+ * Author: Scott Sweeny <scott.sweeny@canonical.com>
75 */
76
77 #ifndef SELFSERVICEBUNDLESQUERY_H
78@@ -28,14 +28,13 @@
79 class SelfServiceBundlesQuery: public unity::scopes::SearchQueryBase
80 {
81 public:
82- SelfServiceBundlesQuery(unity::scopes::CannedQuery const& query, QStringList const& scopes, QString const& locale);
83+ SelfServiceBundlesQuery(unity::scopes::CannedQuery const& query, unity::scopes::SearchMetadata const& metadata);
84
85 virtual void run(unity::scopes::SearchReplyProxy const& reply) override;
86 virtual void cancelled() override;
87
88 private:
89 unity::scopes::CannedQuery query_;
90- QStringList scopes_;
91 };
92
93 #endif
94
95=== modified file 'src/SelfServiceBundlesScope.cpp'
96--- src/SelfServiceBundlesScope.cpp 2014-03-26 16:50:14 +0000
97+++ src/SelfServiceBundlesScope.cpp 2014-06-27 14:07:53 +0000
98@@ -1,6 +1,6 @@
99 /* -*- mode: c; c-basic-offset: 4; indent-tabs-mode: nil -*- */
100 /*
101- * Copyright (C) 2013 Canonical, Ltd.
102+ * Copyright (C) 2014 Canonical, Ltd.
103 *
104 * This program is free software: you can redistribute it and/or modify it
105 * under the terms of the GNU General Public License version 3, as published
106@@ -14,7 +14,7 @@
107 * You should have received a copy of the GNU General Public License along
108 * with this program. If not, see <http://www.gnu.org/licenses/>.
109 *
110- * Author: Pawel Stolowski <pawel.stolowski@canonical.com>
111+ * Author: Scott Sweeny <scott.sweeny@canonical.com>
112 */
113
114 #include "SelfServiceBundlesScope.h"
115@@ -67,22 +67,20 @@
116 delete m_app;
117 }
118
119-int SelfServiceBundlesScope::start(string const&, unity::scopes::RegistryProxy const&)
120+void SelfServiceBundlesScope::start(string const&, unity::scopes::RegistryProxy const&)
121 {
122- return VERSION;
123 }
124
125-SearchQueryBase::UPtr SelfServiceBundlesScope::search(const CannedQuery &query, SearchMetadata const&)
126+SearchQueryBase::UPtr SelfServiceBundlesScope::search(CannedQuery const& query, SearchMetadata const& metadata)
127 {
128- QStringList scopes;
129- SearchQueryBase::UPtr q(new SelfServiceBundlesQuery(query, scopes, m_locale));
130+ SearchQueryBase::UPtr q(new SelfServiceBundlesQuery(query, metadata));
131 return q;
132 }
133
134 PreviewQueryBase::UPtr SelfServiceBundlesScope::preview(Result const& result,
135 ActionMetadata const& hints)
136 {
137- PreviewQueryBase::UPtr previewer(new SelfServiceBundlesPreview(*this, result));
138+ PreviewQueryBase::UPtr previewer(new SelfServiceBundlesPreview(result, hints));
139 return previewer;
140 }
141
142@@ -97,8 +95,8 @@
143 {
144 }
145
146-SelfServiceBundlesPreview::SelfServiceBundlesPreview(SelfServiceBundlesScope &scope, Result const &result)
147- : scope(scope),
148+SelfServiceBundlesPreview::SelfServiceBundlesPreview(Result const &result, ActionMetadata const &metadata)
149+ : PreviewQueryBase(result, metadata),
150 result(result)
151 {
152 }
153
154=== modified file 'src/SelfServiceBundlesScope.h'
155--- src/SelfServiceBundlesScope.h 2014-03-26 16:50:14 +0000
156+++ src/SelfServiceBundlesScope.h 2014-06-27 14:07:53 +0000
157@@ -1,6 +1,6 @@
158 /* -*- mode: c; c-basic-offset: 4; indent-tabs-mode: nil -*- */
159 /*
160- * Copyright (C) 2013 Canonical, Ltd.
161+ * Copyright (C) 2014 Canonical, Ltd.
162 *
163 * This program is free software: you can redistribute it and/or modify it
164 * under the terms of the GNU General Public License version 3, as published
165@@ -14,7 +14,7 @@
166 * You should have received a copy of the GNU General Public License along
167 * with this program. If not, see <http://www.gnu.org/licenses/>.
168 *
169- * Author: Pawel Stolowski <pawel.stolowski@canonical.com>
170+ * Author: Scott Sweeny <scott.sweeny@canonical.com>
171 */
172
173 #ifndef SELFSERVICEBUNDLESSCOPE_H
174@@ -38,7 +38,7 @@
175 SelfServiceBundlesScope();
176 ~SelfServiceBundlesScope();
177
178- virtual int start(std::string const&, unity::scopes::RegistryProxy const&) override;
179+ virtual void start(std::string const&, unity::scopes::RegistryProxy const&) override;
180 virtual void stop() override {}
181 virtual void run() override {}
182 virtual unity::scopes::SearchQueryBase::UPtr search(unity::scopes::CannedQuery const& query, unity::scopes::SearchMetadata const&) override;
183@@ -59,12 +59,12 @@
184 class SelfServiceBundlesPreview : public unity::scopes::PreviewQueryBase
185 {
186 public:
187- SelfServiceBundlesPreview(SelfServiceBundlesScope &scope, unity::scopes::Result const& result);
188+ SelfServiceBundlesPreview(unity::scopes::Result const& result,
189+ unity::scopes::ActionMetadata const& metadata);
190 virtual void cancelled() override;
191 virtual void run(unity::scopes::PreviewReplyProxy const& reply) override;
192
193 private:
194- const SelfServiceBundlesScope &scope;
195 const unity::scopes::Result result;
196 };
197

Subscribers

People subscribed via source and target branches