on xenial help sign in
simplify, don't need the full side stage gesture component
9e8f030Lukáš Tinkl
qml/Stages/WindowControlsOverlay.qml+10−6
@@ -28,16 +28,20 @@ Item {
28
28
29 signal activated
29 signal activated
30
30
31− TabletSideStageTouchGesture {
31+ TouchGestureArea {
32 id: gestureArea
32 id: gestureArea
33 anchors.fill: parent
33 anchors.fill: parent
34
34
35− // NB: for testing, not to clash with unity7 touch overlay controls
35+ // NB: for testing set to 2, not to clash with unity7 touch overlay controls
36− // minimumTouchPoints: 2
36+ minimumTouchPoints: 3
37− // maximumTouchPoints: 2
37+ maximumTouchPoints: minimumTouchPoints
38
38
39− onRecognisedPressChanged: {
39+ readonly property bool recognizedPress: status == TouchGestureArea.Recognized &&
40+ touchPoints.length >= minimumTouchPoints &&
41+ touchPoints.length <= maximumTouchPoints
42+
43+ onRecognizedPressChanged: {
40− if (recognisedPress && target && !target.fullscreen) {
44+ if (recognizedPress && target && !target.fullscreen) {
41 overlayTimer.running = true;
45 overlayTimer.running = true;
42 root.activated();
46 root.activated();
43 }
47 }