Merge lp:~alecu/unity-scope-click/cosmetic-fixes into lp:unity-scope-click/devel

Proposed by Alejandro J. Cura
Status: Merged
Approved by: Alejandro J. Cura
Approved revision: 375
Merged at revision: 379
Proposed branch: lp:~alecu/unity-scope-click/cosmetic-fixes
Merge into: lp:unity-scope-click/devel
Diff against target: 92 lines (+34/-6)
4 files modified
libclickscope/click/configuration.h (+3/-3)
scope/clickapps/apps-query.cpp (+2/-1)
scope/clickstore/store-query.cpp (+4/-2)
scope/tests/test_apps_query.cpp (+25/-0)
To merge this branch: bzr merge lp:~alecu/unity-scope-click/cosmetic-fixes
Reviewer Review Type Date Requested Status
Diego Sarmentero (community) Approve
dobey (community) Approve
PS Jenkins bot (community) continuous-integration Approve
Review via email: mp+229165@code.launchpad.net

Commit message

- Apps category must be expanded (and can't be collapsed).
- Search results category must be expanded.
- Change top 6 apps: phone, messages, contacts, camera, browser, clock.
- Remove "Apps" category title in searches.
- Use art not mascot for app icons in store searches.

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
dobey (dobey) :
review: Approve
Revision history for this message
Diego Sarmentero (diegosarmentero) wrote :

+1

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'libclickscope/click/configuration.h'
2--- libclickscope/click/configuration.h 2014-07-31 19:15:59 +0000
3+++ libclickscope/click/configuration.h 2014-08-01 05:17:22 +0000
4@@ -70,10 +70,10 @@
5 static std::vector<std::string> default_apps {
6 "dialer-app",
7 "messaging-app",
8- "com.ubuntu.calculator_calculator",
9- "com.ubuntu.clock_clock",
10+ "address-book-app",
11 "com.ubuntu.camera_camera",
12- "com.ubuntu.calendar_calendar"
13+ "webbrowser-app",
14+ "com.ubuntu.clock_clock"
15 };
16 return default_apps;
17 }
18
19=== modified file 'scope/clickapps/apps-query.cpp'
20--- scope/clickapps/apps-query.cpp 2014-07-31 20:54:02 +0000
21+++ scope/clickapps/apps-query.cpp 2014-08-01 05:17:22 +0000
22@@ -53,6 +53,7 @@
23 "schema-version" : 1,
24 "template" : {
25 "category-layout" : "grid",
26+ "collapsed-rows": 0,
27 "card-size": "small"
28 },
29 "components" : {
30@@ -357,7 +358,7 @@
31 pusher.push_top_results(localResults, categoryTemplate);
32 }
33
34- const bool show_cat_title = current_dept.empty();
35+ const bool show_cat_title = current_dept.empty() && querystr.empty();
36 pusher.push_local_results(
37 localResults,
38 categoryTemplate,
39
40=== modified file 'scope/clickstore/store-query.cpp'
41--- scope/clickstore/store-query.cpp 2014-07-31 19:25:30 +0000
42+++ scope/clickstore/store-query.cpp 2014-08-01 05:17:22 +0000
43@@ -100,12 +100,14 @@
44 "template" : {
45 "category-layout" : "grid",
46 "card-layout" : "horizontal",
47+ "collapsed-rows": 0,
48 "card-size": "large"
49 },
50 "components" : {
51 "title" : "title",
52- "mascot" : {
53- "field": "art"
54+ "art" : {
55+ "field": "art",
56+ "aspect-ratio": 1.13
57 },
58 "subtitle": "subtitle"
59 }
60
61=== modified file 'scope/tests/test_apps_query.cpp'
62--- scope/tests/test_apps_query.cpp 2014-07-22 20:07:28 +0000
63+++ scope/tests/test_apps_query.cpp 2014-08-01 05:17:22 +0000
64@@ -271,3 +271,28 @@
65 }
66 }
67
68+TEST_F(DepartmentsTest, testNoDepartmentSearch)
69+{
70+ auto clickif = std::make_shared<MockClickInterface>();
71+ auto ptrCat = std::make_shared<FakeCategory>("id", "", "", renderer);
72+ auto depts_db = std::make_shared<MockDepartmentsDb>(":memory:", true);
73+
74+ // query for department-less search
75+ {
76+ const unity::scopes::CannedQuery query("foo.scope", "App", "");
77+
78+ MockAppsQuery q(query, depts_db, metadata, clickif);
79+
80+ scopes::testing::MockSearchReply mock_reply;
81+ scopes::SearchReplyProxy reply(&mock_reply, [](unity::scopes::SearchReply*){});
82+
83+ EXPECT_CALL(*clickif, find_installed_apps(_, _, _)).WillOnce(Return(installed_apps));
84+ EXPECT_CALL(mock_reply, register_category("local", StrEq(""), _, _)).WillOnce(Return(ptrCat));
85+ EXPECT_CALL(mock_reply, register_category("store", _, _, _)).WillOnce(Return(ptrCat));
86+
87+ EXPECT_CALL(mock_reply, push(Matcher<unity::scopes::CategorisedResult const&>(_))).Times(2).WillRepeatedly(Return(true));
88+
89+ q.run(reply);
90+ }
91+}
92+

Subscribers

People subscribed via source and target branches

to all changes: