Mir

Merge lp:~vanvugt/mir/4-finger-release into lp:mir

Proposed by Daniel van Vugt
Status: Merged
Approved by: Alan Griffiths
Approved revision: no longer in the source branch.
Merged at revision: 2814
Proposed branch: lp:~vanvugt/mir/4-finger-release
Merge into: lp:mir
Diff against target: 18 lines (+6/-3)
1 file modified
playground/demo-shell/window_manager.cpp (+6/-3)
To merge this branch: bzr merge lp:~vanvugt/mir/4-finger-release
Reviewer Review Type Date Requested Status
PS Jenkins bot (community) continuous-integration Approve
Chris Halse Rogers Approve
Review via email: mp+266996@code.launchpad.net

Commit message

Playground: Improve 4-finger swipe recognition that got broken
slightly in r2564. Now it recognises that multiple fingers might get
released simultaneously, like it used to.

Description of the change

Related to, but not a fix for bug 1481570.

To post a comment you must log in.
Revision history for this message
Chris Halse Rogers (raof) wrote :

Seems sensible

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

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'playground/demo-shell/window_manager.cpp'
2--- playground/demo-shell/window_manager.cpp 2015-06-17 05:20:42 +0000
3+++ playground/demo-shell/window_manager.cpp 2015-08-05 05:08:42 +0000
4@@ -477,9 +477,12 @@
5 bool last_touch_released(MirTouchEvent const* tev)
6 {
7 auto count = mir_touch_event_point_count(tev);
8- if (count > 1)
9- return false;
10- return mir_touch_event_action(tev, 0) == mir_touch_action_up;
11+ for (unsigned i = 0; i < count; ++i)
12+ {
13+ if (mir_touch_event_action(tev, i) != mir_touch_action_up)
14+ return false;
15+ }
16+ return true;
17 }
18 }
19

Subscribers

People subscribed via source and target branches