Merge lp:~marcustomlinson/unity-scopes-shell/rename_child_scopes_methods into lp:unity-scopes-shell

Proposed by Marcus Tomlinson
Status: Merged
Approved by: Paweł Stołowski
Approved revision: 207
Merged at revision: 205
Proposed branch: lp:~marcustomlinson/unity-scopes-shell/rename_child_scopes_methods
Merge into: lp:unity-scopes-shell
Diff against target: 106 lines (+12/-11)
5 files modified
CMakeLists.txt (+1/-1)
debian/control (+1/-1)
src/Unity/overviewresults.cpp (+4/-3)
src/Unity/settingsmodel.cpp (+3/-3)
tests/data/mock-scope-departments/mock-scope-departments.cpp (+3/-3)
To merge this branch: bzr merge lp:~marcustomlinson/unity-scopes-shell/rename_child_scopes_methods
Reviewer Review Type Date Requested Status
Paweł Stołowski (community) Approve
PS Jenkins bot (community) continuous-integration Needs Fixing
Review via email: mp+254034@code.launchpad.net

Commit message

Rename "child_scopes()" to "find_child_scopes()" and "child_scopes_ordered()" to "child_scopes()" as the ordering constraint has been removed.

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
207. By Marcus Tomlinson

Updated according to new unity-scopes 0.6.15 changes

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
Paweł Stołowski (stolowski) wrote :

LGTM.

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 2015-03-09 15:57:49 +0000
3+++ CMakeLists.txt 2015-04-01 13:49:23 +0000
4@@ -50,7 +50,7 @@
5 find_package(Qt5Test)
6 find_package(Boost COMPONENTS regex REQUIRED)
7
8-pkg_check_modules(SCOPESLIB REQUIRED libunity-scopes>=0.6.12)
9+pkg_check_modules(SCOPESLIB REQUIRED libunity-scopes>=0.6.15)
10 pkg_check_modules(SCOPES_API REQUIRED unity-shell-scopes=6)
11
12 # Standard install paths
13
14=== modified file 'debian/control'
15--- debian/control 2015-03-03 10:52:45 +0000
16+++ debian/control 2015-04-01 13:49:23 +0000
17@@ -7,7 +7,7 @@
18 libboost-python-dev,
19 libboost-regex-dev,
20 libunity-api-dev (>= 7.96),
21- libunity-scopes-dev (>= 0.6.12~),
22+ libunity-scopes-dev (>= 0.6.15~),
23 libgsettings-qt-dev (>= 0.1),
24 libqtdbustest1-dev (>= 0.2),
25 libqtdbusmock1-dev (>= 0.2),
26
27=== modified file 'src/Unity/overviewresults.cpp'
28--- src/Unity/overviewresults.cpp 2015-02-02 08:05:59 +0000
29+++ src/Unity/overviewresults.cpp 2015-04-01 13:49:23 +0000
30@@ -25,6 +25,7 @@
31 #include "utils.h"
32
33 #include <unity/scopes/Result.h>
34+#include <unity/scopes/Scope.h>
35 #include <QSet>
36
37 namespace scopes_ng {
38@@ -151,7 +152,7 @@
39 {
40 ///!===
41 /// TODO: This code should be removed as soon as we can remove child_scope_ids() from ScopeMetadata.
42- /// Aggregators should now be implementing the child_scopes() method rather than setting ChildScopes in config.
43+ /// Aggregators should now be implementing the find_child_scopes() method rather than setting ChildScopes in config.
44 auto const children = scopeMetadata->child_scope_ids();
45 if (children.size())
46 {
47@@ -177,11 +178,11 @@
48 unity::scopes::ChildScopeList children;
49 try
50 {
51- children = scopeMetadata->proxy()->child_scopes_ordered();
52+ children = scopeMetadata->proxy()->child_scopes();
53 }
54 catch (std::exception const& e)
55 {
56- qWarning("OverviewResultsModel::updateChildScopes: Exception caught from proxy()->child_scopes_ordered(): %s", e.what());
57+ qWarning("OverviewResultsModel::updateChildScopes: Exception caught from proxy()->child_scopes(): %s", e.what());
58 return false;
59 }
60
61
62=== modified file 'src/Unity/settingsmodel.cpp'
63--- src/Unity/settingsmodel.cpp 2015-02-03 08:28:40 +0000
64+++ src/Unity/settingsmodel.cpp 2015-04-01 13:49:23 +0000
65@@ -199,7 +199,7 @@
66 m_scopeProxy = scopes_metadata[m_scopeId]->proxy();
67 try
68 {
69- m_child_scopes = m_scopeProxy->child_scopes_ordered();
70+ m_child_scopes = m_scopeProxy->child_scopes();
71 }
72 catch (std::exception const& e)
73 {
74@@ -313,11 +313,11 @@
75 {
76 try
77 {
78- m_scopeProxy->set_child_scopes_ordered(m_child_scopes);
79+ m_scopeProxy->set_child_scopes(m_child_scopes);
80 }
81 catch (std::exception const& e)
82 {
83- qWarning("SettingsModel::settings_timeout: Exception caught from m_scopeProxy->set_child_scopes_ordered(): %s", e.what());
84+ qWarning("SettingsModel::settings_timeout: Exception caught from m_scopeProxy->set_child_scopes(): %s", e.what());
85 return;
86 }
87 }
88
89=== modified file 'tests/data/mock-scope-departments/mock-scope-departments.cpp'
90--- tests/data/mock-scope-departments/mock-scope-departments.cpp 2015-02-23 12:13:14 +0000
91+++ tests/data/mock-scope-departments/mock-scope-departments.cpp 2015-04-01 13:49:23 +0000
92@@ -170,11 +170,11 @@
93 return nullptr;
94 }
95
96- virtual ChildScopeList child_scopes() const
97+ virtual ChildScopeList find_child_scopes() const
98 {
99 ChildScopeList list;
100- list.push_back({"mock-scope-double-nav", true});
101- list.push_back({"mock-scope", true});
102+ list.push_back({"mock-scope-double-nav", registry()->get_metadata("mock-scope-double-nav"), true});
103+ list.push_back({"mock-scope", registry()->get_metadata("mock-scope"), true});
104 return list;
105 }
106 };

Subscribers

People subscribed via source and target branches

to all changes: