Restore focus to pw input after switching back from sessions list
commit50b5e9d6065657ead8054ec4aafc6de8392a7ecc
authorJosh Arenson <joshua.arenson@canonical.com>
dateMon 8 Aug 2016, 18:56 (10 years ago)
parentab4f167
qml/Greeter/LoginList.qml+1
@@ -30,6 +30,7 @@ StyledItem {
3030 property bool locked
3131 property bool waiting
3232
33+ readonly property alias passwordInput: passwordInput
3334 readonly property int numAboveBelow: 4
3435 readonly property int cellHeight: units.gu(5)
3536 readonly property int highlightedHeight: units.gu(15)
qml/Greeter/WideView.qml+4−1
@@ -162,7 +162,10 @@ FocusScope {
162162 Connections {
163163 target: sessionChooserLoader.item
164164 onSessionSelected: loginList.currentSession = sessionKey
165− onShowLoginList: coverPage.state = "LoginList"
165+ onShowLoginList: {
166+ coverPage.state = "LoginList"
167+ loginList.passwordInput.forceActiveFocus();
168+ }
166169 ignoreUnknownSignals: true
167170 }
168171 }