diff options
author | Andreas Hartmetz <andreas.hartmetz@kdab.com> | 2016-12-02 16:42:19 +0100 |
---|---|---|
committer | Andreas Hartmetz <andreas.hartmetz@kdab.com> | 2016-12-07 17:14:03 +0000 |
commit | a210e423a334e33acd9b5c9d9fcdc13ed1a1a9ca (patch) | |
tree | d0a21a16c87fbcb131e677944265ba35f21a797f /sysui/Climate/ClimateBar.qml | |
parent | fc298ccec2ef0186cba29b0c7e565ee23e733628 (diff) |
Ventilation item: fix changes by more than one step
Previously, two things did not work:
- Changing by more than one level by directly tapping on the
desired level. This was apparently intended to work but
didn't, from looking at the code.
- Changing by more than one level from the backend
In both cases, the NumberAnimation on the view's index which was
aliased to the ventilation level caused a changed signal for
every step change, which, because it was the most recent change,
became *the* change and caused the final value to fall short of
the actual target value.
After the core fix, a similar fix to the previous one is needed
to make the backend to UI propagation work at all again. But
then it works right.
Change-Id: I31d7f247203cf25b17d06d0eb4edc7af81af4334
Reviewed-by: Nedim Hadzic <nedim.hadzic@pelagicore.com>
Diffstat (limited to 'sysui/Climate/ClimateBar.qml')
-rw-r--r-- | sysui/Climate/ClimateBar.qml | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sysui/Climate/ClimateBar.qml b/sysui/Climate/ClimateBar.qml index 3a9c2c7..f391b6c 100644 --- a/sysui/Climate/ClimateBar.qml +++ b/sysui/Climate/ClimateBar.qml @@ -162,6 +162,10 @@ UIElement { levels: ClimateService.ventilationLevels currentLevel: ClimateService.ventilation onCurrentLevelChanged: ClimateService.ventilation = currentLevel + Connections { + target: ClimateService + onVentilationChanged: ventilation.currentLevel = ClimateService.ventilation + } } Spacer { |