diff options
author | J-P Nurmi <jpnurmi@qt.io> | 2017-09-27 13:20:02 +0200 |
---|---|---|
committer | J-P Nurmi <jpnurmi@qt.io> | 2017-09-28 09:49:21 +0000 |
commit | d1e0d56946ab54d4777315dbb5116d95ce24601b (patch) | |
tree | 608af32ed7707350fcd74977cb2ab834dcd1ed20 /src/imports | |
parent | 7e85c09d2575a21a4e4e57eb4a275918ca10f4fd (diff) |
Default: make SwitchIndicator use palettes
Task-number: QTBUG-63369
Change-Id: Ife154914e49dd7946046984c61b22b551f6f7817
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Diffstat (limited to 'src/imports')
-rw-r--r-- | src/imports/controls/SwitchIndicator.qml | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/src/imports/controls/SwitchIndicator.qml b/src/imports/controls/SwitchIndicator.qml index c8bfc9b9..0aeaaffc 100644 --- a/src/imports/controls/SwitchIndicator.qml +++ b/src/imports/controls/SwitchIndicator.qml @@ -49,9 +49,7 @@ Item { width: 56 height: 16 radius: 8 - color: control.checked ? (control.visualFocus ? control.palette.highlight : Default.buttonCheckedColor) : Default.buttonColor - border.width: control.visualFocus ? 2 : 0 - border.color: control.palette.highlight + color: control.checked ? control.palette.dark : control.palette.midlight } Rectangle { @@ -60,13 +58,9 @@ Item { width: 28 height: 28 radius: 16 - color: control.enabled ? (control.down - ? (control.visualFocus ? Default.focusPressedColor : Default.indicatorPressedColor) - : (control.visualFocus ? Default.focusLightColor : Default.backgroundColor)) : Default.indicatorDisabledColor + color: control.down ? control.palette.light : control.palette.window border.width: control.visualFocus ? 2 : 1 - border.color: control.enabled ? (control.visualFocus - ? control.palette.highlight - : (control.down ? Default.indicatorFramePressedColor : Default.indicatorFrameColor)) : Default.indicatorFrameDisabledColor + border.color: control.visualFocus ? control.palette.highlight : control.enabled ? control.palette.mid : control.palette.midlight Behavior on x { enabled: !control.down |