Merge lp:~mhr3/unity-lens-shopping/revert-r23 into lp:unity-lens-shopping

Proposed by Michal Hruby
Status: Merged
Approved by: Neil J. Patel
Approved revision: 25
Merged at revision: 25
Proposed branch: lp:~mhr3/unity-lens-shopping/revert-r23
Merge into: lp:unity-lens-shopping
Diff against target: 64 lines (+4/-36)
2 files modified
src/scope.vala (+4/-23)
tests/manual-tests/shopping-lens-tests.txt (+0/-13)
To merge this branch: bzr merge lp:~mhr3/unity-lens-shopping/revert-r23
Reviewer Review Type Date Requested Status
Neil J. Patel (community) Approve
Review via email: mp+126979@code.launchpad.net

Commit message

Revert r23

Description of the change

Revert r23, because... No there isn't a logical reason for that, sorry...

To post a comment you must log in.
Revision history for this message
Neil J. Patel (njpatel) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/scope.vala'
2--- src/scope.vala 2012-09-27 08:40:46 +0000
3+++ src/scope.vala 2012-09-28 14:31:09 +0000
4@@ -383,32 +383,13 @@
5
6 if (image_uri != "")
7 {
8+ // TODO: what to do if we have price but no icon?
9 var file = File.new_for_uri (image_uri);
10 var icon = new AnnotatedIcon (new FileIcon (file));
11 // FIXME: dash doesn't like empty string as ribbon
12- icon.ribbon = price == null || price == "" ? " " : price;
13-
14- unowned string category = "";
15- if (result.has_member ("category"))
16- category = result.get_string_member ("category");
17- switch (category)
18- {
19- case "application":
20- icon.category = CategoryType.APPLICATION;
21- break;
22- case "movie":
23- icon.category = CategoryType.MOVIE;
24- break;
25- case "music":
26- icon.category = CategoryType.MUSIC;
27- break;
28- case "book":
29- icon.category = CategoryType.BOOK;
30- break;
31- default:
32- icon.category = CategoryType.HOME; // will use generic icon
33- break;
34- }
35+ icon.ribbon = price == null || price == "" ? " " : price;
36+ // FIXME: the service doesn't expose categories yet
37+ // icon.category = CategoryType.BOOK;
38 image_uri = icon.to_string ();
39 }
40
41
42=== modified file 'tests/manual-tests/shopping-lens-tests.txt'
43--- tests/manual-tests/shopping-lens-tests.txt 2012-09-27 08:46:19 +0000
44+++ tests/manual-tests/shopping-lens-tests.txt 2012-09-28 14:31:09 +0000
45@@ -70,19 +70,6 @@
46 Expected Results:
47 Web site for selected item is opened in web browser, with an option to complete purchase.
48
49-Emblems on icons provided by the Shopping lens
50-----------------------------------------------------
51-Whenever there are results from the shopping lens, emblems are present on the icons.
52-
53-Setup:
54-Internet connectivity.
55-
56-Actions:
57-Perform a search so that some results in the "More suggestions" category are displayed. (for example search for "novel")
58-
59-Expected Results:
60-All items that are displayed have an icon categorizing the product - either a music icon, book, movie, or a generic shopping bag icon along with a price.
61-
62 'Disable' Shopping Lens Search
63 ----------------------------------------------------
64 Disabling the shopping lens should not show any result.

Subscribers

People subscribed via source and target branches

to all changes: