Merge lp:~seb128/ubuntu-system-settings/security-focus-correct-entry into lp:ubuntu-system-settings

Proposed by Sebastien Bacher on 2015-03-31
Status: Merged
Approved by: Jonas G. Drange on 2015-04-16
Approved revision: 1362
Merged at revision: 1382
Proposed branch: lp:~seb128/ubuntu-system-settings/security-focus-correct-entry
Merge into: lp:ubuntu-system-settings
Diff against target: 26 lines (+8/-1)
1 file modified
plugins/security-privacy/LockSecurity.qml (+8/-1)
To merge this branch: bzr merge lp:~seb128/ubuntu-system-settings/security-focus-correct-entry
Reviewer Review Type Date Requested Status
Jonas G. Drange (community) Approve on 2015-04-16
Ken VanDine 2015-03-31 Approve on 2015-04-03
PS Jenkins bot continuous-integration Needs Fixing on 2015-03-31
Review via email: mp+254804@code.launchpad.net

Commit Message

[security-privacy] give the focus to the right entry, if the current
unlock method is swipe then there is no "current password" so the new
input line should be the focussed one

Description of the Change

[security-privacy] give the focus to the right entry, if the current
unlock method is swipe then there is no "current password" so the new
input line should be the focussed one

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'plugins/security-privacy/LockSecurity.qml'
2--- plugins/security-privacy/LockSecurity.qml 2015-02-09 15:46:27 +0000
3+++ plugins/security-privacy/LockSecurity.qml 2015-03-31 17:22:36 +0000
4@@ -181,7 +181,10 @@
5 UbuntuSecurityPrivacyPanel.Swipe)
6 confirmButton.enabled = text.length > 0
7 }
8- Component.onCompleted: forceActiveFocus()
9+ Component.onCompleted: {
10+ if (securityPrivacy.securityType !== UbuntuSecurityPrivacyPanel.Swipe)
11+ forceActiveFocus()
12+ }
13 }
14
15 /* Using bindings since it is, according to documentation,
16@@ -244,6 +247,10 @@
17 changeSecurityDialog.newMethod ===
18 UbuntuSecurityPrivacyPanel.Passphrase
19 onTextChanged: { displayMismatchWarning() }
20+ Component.onCompleted: {
21+ if (securityPrivacy.securityType === UbuntuSecurityPrivacyPanel.Swipe)
22+ forceActiveFocus()
23+ }
24 }
25
26 /* Using bindings since it is, according to documentation,

Subscribers

People subscribed via source and target branches