From 024aa99be7919aaee2bcc5ec66991bf348ea492e Mon Sep 17 00:00:00 2001 From: Louis-Joseph Fournier Date: Thu, 14 Jan 2016 16:51:42 +0100 Subject: [PATCH] PlayerScreen: disallow navigation when toise pressed --- qml/PlayerScreen.qml | 2 ++ qml/Sailfish.qml | 4 ++++ qml/ToiseFlickable.qml | 4 ++++ 3 files changed, 10 insertions(+) diff --git a/qml/PlayerScreen.qml b/qml/PlayerScreen.qml index 17e39fd..b61ca5f 100644 --- a/qml/PlayerScreen.qml +++ b/qml/PlayerScreen.qml @@ -38,6 +38,8 @@ Item { // landscape / portrait property bool is_portrait: height > width + property bool toisepressed: toise.pressed || toise_octave.pressed + // frequency and temperament Column { id: freq_temp diff --git a/qml/Sailfish.qml b/qml/Sailfish.qml index 15c6ed7..a31cd2c 100644 --- a/qml/Sailfish.qml +++ b/qml/Sailfish.qml @@ -96,8 +96,12 @@ ApplicationWindow { property bool playing: false property bool tunerPlaying: playing && status == PageStatus.Active + backNavigation: !screen.toisepressed + SilicaFlickable { + id: flick anchors.fill: parent + interactive: !screen.toisepressed PullDownMenu { MenuItem { diff --git a/qml/ToiseFlickable.qml b/qml/ToiseFlickable.qml index 5e6acb9..b6ccee0 100644 --- a/qml/ToiseFlickable.qml +++ b/qml/ToiseFlickable.qml @@ -32,10 +32,14 @@ Toise { property double p_min: index2pos(min) property double p_max: index2pos(max) + property alias pressed: area.pressed + signal released() //animation_enabled: false MouseArea { + id: area + property int refX: 0 property double refPos: parent.position