summaryrefslogtreecommitdiffstats
path: root/mobile-widgets/qml/CloudCredentials.qml
diff options
context:
space:
mode:
authorGravatar Joakim Bygdell <j.bygdell@gmail.com>2017-07-24 20:04:47 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2017-07-26 01:39:26 +0900
commit071db08b141def6dd5b89e4b79159e29f56c6c0b (patch)
tree7025e7b188f27bae131817a62f6f3c8b51c9e6c1 /mobile-widgets/qml/CloudCredentials.qml
parent93ec03105e58e128a363fcf25521e7b0e06e5c9d (diff)
downloadsubsurface-071db08b141def6dd5b89e4b79159e29f56c6c0b.tar.gz
QML UI: replace all switches with our own
As per title, helps simplify theme modifications. Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
Diffstat (limited to 'mobile-widgets/qml/CloudCredentials.qml')
-rw-r--r--mobile-widgets/qml/CloudCredentials.qml23
1 files changed, 1 insertions, 22 deletions
diff --git a/mobile-widgets/qml/CloudCredentials.qml b/mobile-widgets/qml/CloudCredentials.qml
index 72a5ccb12..fd667c00c 100644
--- a/mobile-widgets/qml/CloudCredentials.qml
+++ b/mobile-widgets/qml/CloudCredentials.qml
@@ -96,7 +96,7 @@ Item {
text: qsTr("Show password")
Layout.preferredWidth: col1Width
}
- Switch {
+ SsrfSwitch {
checked: false
id: showPassword
Layout.preferredWidth: col2Width
@@ -105,27 +105,6 @@ Item {
password.text = "" // don't show a hidden password
password.echoMode = checked ? TextInput.Normal : TextInput.Password
}
- indicator: Rectangle {
- implicitWidth: Kirigami.Units.largeSpacing * 3
- implicitHeight: Kirigami.Units.largeSpacing
- x: showPassword.leftPadding
- y: parent.height / 2 - height / 2
- radius: Kirigami.Units.largeSpacing * 0.5
- color: showPassword.checked ?
- subsurfaceTheme.lightPrimaryColor : subsurfaceTheme.backgroundColor
- border.color: subsurfaceTheme.darkerPrimaryColor
-
- Rectangle {
- x: showPassword.checked ? parent.width - width : 0
- y: parent.height / 2 - height / 2
- width: Kirigami.Units.largeSpacing * 1.5
- height: Kirigami.Units.largeSpacing * 1.5
- radius: height / 2
- color: showPassword.down || showPassword.checked ?
- subsurfaceTheme.primaryColor : subsurfaceTheme.lightPrimaryColor
- border.color: subsurfaceTheme.darkerPrimaryColor
- }
- }
}
}