Merge lp://qastaging/~stolowski/unity-scope-home/filters into lp://qastaging/unity-scope-home

Proposed by Paweł Stołowski
Status: Merged
Approved by: Michal Hruby
Approved revision: 73
Merged at revision: 70
Proposed branch: lp://qastaging/~stolowski/unity-scope-home/filters
Merge into: lp://qastaging/unity-scope-home
Diff against target: 276 lines (+156/-18)
3 files modified
src/scope.vala (+50/-17)
src/search-query-state.vala (+1/-1)
src/search-util.vala (+105/-0)
To merge this branch: bzr merge lp://qastaging/~stolowski/unity-scope-home/filters
Reviewer Review Type Date Requested Status
PS Jenkins bot (community) continuous-integration Approve
Michal Hruby (community) Approve
Review via email: mp+154206@code.qastaging.launchpad.net

Commit message

Light up filters according to recommendations and searched scopes.

Description of the change

Light up filters according to recommendations and searched scopes.

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
Michal Hruby (mhr3) wrote :

7 var cat_filter = new Unity.CheckOptionFilter ("categories", "Categories"); //TODO intl
8 + cat_filter.show_all_button = false;
9 cat_filter.sort_type = Unity.OptionsFilter.SortType.DISPLAY_NAME;
10
11 + var src_filter = new Unity.CheckOptionFilter ("sources", "Sources");

Why aren't the strings _()-ed?

123 + opt.active = rec_lookup.contains (opt.id) && mgr.get_result_count (home_channel, master_scope_id) > 0;

Isn't the result count check being done too early? Were the scopes actually queried and did they have time to return results at this point?

69. By Paweł Stołowski

Define i18n-friendly filter names.

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
70. By Paweł Stołowski

Take result counts into account when updating filter state.

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
71. By Paweł Stołowski

Highlight filters also for normal search.

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

> 7 var cat_filter = new Unity.CheckOptionFilter ("categories",
> "Categories"); //TODO intl
> 8 + cat_filter.show_all_button = false;
> 9 cat_filter.sort_type = Unity.OptionsFilter.SortType.DISPLAY_NAME;
> 10
> 11 + var src_filter = new Unity.CheckOptionFilter ("sources",
> "Sources");
>
> Why aren't the strings _()-ed?

Fixed.

>
> 123 + opt.active = rec_lookup.contains (opt.id) &&
> mgr.get_result_count (home_channel, master_scope_id) > 0;
>
> Isn't the result count check being done too early? Were the scopes actually
> queried and did they have time to return results at this point?

Good point. Fixed (requires flush-model branch of libunity to work properly).

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
72. By Paweł Stołowski

Removed comment.

73. By Paweł Stołowski

Formatting.

Revision history for this message
Michal Hruby (mhr3) wrote :

Let's get this in.

review: Approve
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches

to all changes: