diff options
author | Stephane Desneux <stephane.desneux@iot.bzh> | 2016-12-14 18:55:59 +0000 |
---|---|---|
committer | Jan-Simon Moeller <jsmoeller@linuxfoundation.org> | 2016-12-15 02:52:46 +0000 |
commit | c472e565e6b7918d0b9554cb1b2c6c86f3ffbef5 (patch) | |
tree | 9b72e4b9263dd039e59a435e6b898df43cd8aa3e /app/HVAC.qml | |
parent | 2fec4fc2386bef72c209fbd7fc51d4f4cbfca92a (diff) |
app: use range [0..255] for slider, send temperatures updates
Change-Id: I020b2a1c14d09be99e4ecfe645915a666b7759ea
Signed-off-by: Stephane Desneux <stephane.desneux@iot.bzh>
Diffstat (limited to 'app/HVAC.qml')
-rw-r--r-- | app/HVAC.qml | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/app/HVAC.qml b/app/HVAC.qml index f5cd76b..41cf7fa 100644 --- a/app/HVAC.qml +++ b/app/HVAC.qml @@ -46,6 +46,9 @@ ApplicationWindow { anchors.left: parent.left anchors.right: parent.right anchors.verticalCenter: parent.verticalCenter + from: 0.0 + to: 255.0 + stepSize: 1.0 onValueChanged: { binding.fanSpeed = value } @@ -72,6 +75,10 @@ ApplicationWindow { } HeatDegree { enabled: leftSeat.headLevel > 0 + onCurrentItemChanged: { + console.log("Left Temp changed",degree) + binding.leftTemperature = degree + } } } ColumnLayout { @@ -121,6 +128,10 @@ ApplicationWindow { } HeatDegree { enabled: rightSeat.headLevel > 0 + onCurrentItemChanged: { + console.log("Right Temp changed",degree) + binding.rightTemperature = degree + } } } } |