Merge lp:~nicolas-doffay/unity/coverflow-mouse-select-fix into lp:unity

Proposed by Nicolas d'Offay on 2012-09-10
Status: Merged
Merged at revision: 2701
Proposed branch: lp:~nicolas-doffay/unity/coverflow-mouse-select-fix
Merge into: lp:unity
Diff against target: 19 lines (+5/-3)
1 file modified
dash/CoverflowResultView.cpp (+5/-3)
To merge this branch: bzr merge lp:~nicolas-doffay/unity/coverflow-mouse-select-fix
Reviewer Review Type Date Requested Status
Neil J. Patel (community) 2012-09-10 Approve on 2012-09-19
Review via email: mp+123574@code.launchpad.net

Description of the Change

Fixed mouse button selection for the CoverflowResultView. Left click and right click take you to previews, scroll click launches song.

To post a comment you must log in.
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 'dash/CoverflowResultView.cpp'
2--- dash/CoverflowResultView.cpp 2012-08-23 14:23:08 +0000
3+++ dash/CoverflowResultView.cpp 2012-09-10 15:32:19 +0000
4@@ -124,10 +124,12 @@
5
6 void CoverflowResultItem::Activate(int button)
7 {
8- if (button == 1)
9+ //Left and right click take you to previews.
10+ if (button == 1 || button == 3)
11+ parent_->UriActivated.emit(result_.uri, ResultView::ActivateType::PREVIEW);
12+ //Scroll click opens up music player.
13+ else if (button == 2)
14 parent_->UriActivated.emit(result_.uri, ResultView::ActivateType::DIRECT);
15- else if (button == 3)
16- parent_->UriActivated.emit(result_.uri, ResultView::ActivateType::PREVIEW);
17
18 int index = Index();
19 int size = model_->Items().size();