Merge lp:~jonas-drange/ubuntu-system-settings/lp1470782 into lp:ubuntu-system-settings
- lp1470782
- Merge into trunk
Status: | Merged |
---|---|
Approved by: | Ken VanDine |
Approved revision: | 1475 |
Merged at revision: | 1490 |
Proposed branch: | lp:~jonas-drange/ubuntu-system-settings/lp1470782 |
Merge into: | lp:ubuntu-system-settings |
Diff against target: |
1076 lines (+532/-427) 9 files modified
plugins/phone/Services.qml (+23/-10) plugins/security-privacy/AppAccess.qml (+52/-40) plugins/security-privacy/AppAccessControl.qml (+30/-18) plugins/security-privacy/LockSecurity.qml (+83/-71) plugins/security-privacy/PhoneLocking.qml (+112/-100) plugins/security-privacy/SimPin.qml (+102/-90) plugins/security-privacy/diagnostics/PageComponent.qml (+8/-1) plugins/wifi/NetworkDetails.qml (+69/-56) plugins/wifi/NetworkDetailsBrief.qml (+53/-41) |
To merge this branch: | bzr merge lp:~jonas-drange/ubuntu-system-settings/lp1470782 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
PS Jenkins bot | continuous-integration | Needs Fixing | |
Sebastien Bacher (community) | Approve | ||
Review via email: mp+264551@code.launchpad.net |
Commit message
Adds Flickables to many pages.
Description of the change
Add Flickables to panels that are without.
Sebastien Bacher (seb128) wrote : | # |
- 1475. By Jonas G. Drange
-
undo visual changes
Jonas G. Drange (jonas-drange) wrote : | # |
Agreed, undid the visual changes. All changes are now strictly related to the addition of Flickables.
Sebastien Bacher (seb128) wrote : | # |
seems to do what it should now!
PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:1474
http://
Executed test runs:
UNSTABLE: http://
SUCCESS: http://
SUCCESS: http://
UNSTABLE: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
Click here to trigger a rebuild:
http://
PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:1475
http://
Executed test runs:
UNSTABLE: http://
SUCCESS: http://
SUCCESS: http://
UNSTABLE: http://
SUCCESS: http://
deb: http://
SUCCESS: http://
Click here to trigger a rebuild:
http://
- 1476. By Jonas G. Drange
-
skip adding flickable to timedate
Matthew Paul Thomas (mpt) wrote : | # |
As I said in bug 1470782, I'm not a software architect, but this seems error-prone. Every time someone adds a new page to System Settings, they have to know and remember to add a Flickable, which is unlikely when the screen on their test device happens to be larger than the page contents when they test it. I predict that bugs like bug 1240086, bug 1333135, bug 1354161, bug 1374017, bug 1469076, and bug 1470782 will keep recurring as long as people have to remember to add a Flickable to every page.
And that was before I'd even seen this diff, which includes this comment nine times:
/* Set the direction to workaround
https:/
might end up in a situation where scrolling doesn't work */
When that Qt bug is fixed, if you get around to removing the workaround, you'll be removing it from at least 24 separate files. If it was part of a base file you'd just need to remove it in one place.
Is there a reason not to make every System Settings page inherit from one file that includes the Flickable?
Preview Diff
1 | === modified file 'plugins/phone/Services.qml' | |||
2 | --- plugins/phone/Services.qml 2014-08-06 12:12:31 +0000 | |||
3 | +++ plugins/phone/Services.qml 2015-07-16 14:21:51 +0000 | |||
4 | @@ -24,6 +24,7 @@ | |||
5 | 24 | import Ubuntu.Components.ListItems 0.1 as ListItem | 24 | import Ubuntu.Components.ListItems 0.1 as ListItem |
6 | 25 | 25 | ||
7 | 26 | ItemPage { | 26 | ItemPage { |
8 | 27 | id: root | ||
9 | 27 | objectName: "servicesPage" | 28 | objectName: "servicesPage" |
10 | 28 | title: headerTitle | 29 | title: headerTitle |
11 | 29 | property string carrierString | 30 | property string carrierString |
12 | @@ -42,16 +43,28 @@ | |||
13 | 42 | names = keys; | 43 | names = keys; |
14 | 43 | } | 44 | } |
15 | 44 | 45 | ||
26 | 45 | Column { | 46 | Flickable { |
27 | 46 | anchors.left: parent.left | 47 | anchors.fill: parent |
28 | 47 | anchors.right: parent.right | 48 | contentHeight: contentItem.childrenRect.height |
29 | 48 | Repeater { | 49 | boundsBehavior: (contentHeight > root.height) ? |
30 | 49 | model: names | 50 | Flickable.DragAndOvershootBounds : |
31 | 50 | 51 | Flickable.StopAtBounds | |
32 | 51 | ListItem.Standard { | 52 | /* Set the direction to workaround |
33 | 52 | progression: true | 53 | https://bugreports.qt-project.org/browse/QTBUG-31905 otherwise the UI |
34 | 53 | text: modelData | 54 | might end up in a situation where scrolling doesn't work */ |
35 | 54 | onClicked: pageStack.push(Qt.resolvedUrl("ServiceInfo.qml"), {serviceName: modelData, serviceNumber: sim.serviceNumbers[modelData]}) | 55 | flickableDirection: Flickable.VerticalFlick |
36 | 56 | |||
37 | 57 | Column { | ||
38 | 58 | anchors.left: parent.left | ||
39 | 59 | anchors.right: parent.right | ||
40 | 60 | Repeater { | ||
41 | 61 | model: names | ||
42 | 62 | |||
43 | 63 | ListItem.Standard { | ||
44 | 64 | progression: true | ||
45 | 65 | text: modelData | ||
46 | 66 | onClicked: pageStack.push(Qt.resolvedUrl("ServiceInfo.qml"), {serviceName: modelData, serviceNumber: sim.serviceNumbers[modelData]}) | ||
47 | 67 | } | ||
48 | 55 | } | 68 | } |
49 | 56 | } | 69 | } |
50 | 57 | } | 70 | } |
51 | 58 | 71 | ||
52 | === modified file 'plugins/security-privacy/AppAccess.qml' | |||
53 | --- plugins/security-privacy/AppAccess.qml 2014-08-05 09:20:11 +0000 | |||
54 | +++ plugins/security-privacy/AppAccess.qml 2015-07-16 14:21:51 +0000 | |||
55 | @@ -27,46 +27,58 @@ | |||
56 | 27 | id: root | 27 | id: root |
57 | 28 | title: i18n.tr("Other app access") | 28 | title: i18n.tr("Other app access") |
58 | 29 | 29 | ||
99 | 30 | Column { | 30 | Flickable { |
100 | 31 | anchors.left: parent.left | 31 | anchors.fill: parent |
101 | 32 | anchors.right: parent.right | 32 | contentHeight: contentItem.childrenRect.height |
102 | 33 | 33 | boundsBehavior: (contentHeight > root.height) ? | |
103 | 34 | ListItem.Caption { | 34 | Flickable.DragAndOvershootBounds : |
104 | 35 | text: i18n.tr("Apps that you have granted and have requested access to:") | 35 | Flickable.StopAtBounds |
105 | 36 | } | 36 | /* Set the direction to workaround |
106 | 37 | 37 | https://bugreports.qt-project.org/browse/QTBUG-31905 otherwise the UI | |
107 | 38 | ListModel { | 38 | might end up in a situation where scrolling doesn't work */ |
108 | 39 | id: appsModel | 39 | flickableDirection: Flickable.VerticalFlick |
109 | 40 | ListElement { | 40 | |
110 | 41 | name: QT_TR_NOOP("Camera") | 41 | Column { |
111 | 42 | caption: QT_TR_NOOP("Apps that have requested access to your camera") | 42 | anchors.left: parent.left |
112 | 43 | trustStoreService: "CameraService" | 43 | anchors.right: parent.right |
113 | 44 | } | 44 | |
114 | 45 | ListElement { | 45 | ListItem.Caption { |
115 | 46 | name: QT_TR_NOOP("Mic") | 46 | text: i18n.tr("Apps that you have granted and have requested access to:") |
116 | 47 | caption: QT_TR_NOOP("Apps that have requested access to your mic") | 47 | } |
117 | 48 | trustStoreService: "PulseAudio" | 48 | |
118 | 49 | } | 49 | ListModel { |
119 | 50 | } | 50 | id: appsModel |
120 | 51 | 51 | ListElement { | |
121 | 52 | Repeater { | 52 | name: QT_TR_NOOP("Camera") |
122 | 53 | model: appsModel | 53 | caption: QT_TR_NOOP("Apps that have requested access to your camera") |
123 | 54 | 54 | trustStoreService: "CameraService" | |
124 | 55 | ListItem.SingleValue { | 55 | } |
125 | 56 | text: model.name | 56 | ListElement { |
126 | 57 | enabled: trustStoreModel.count > 0 | 57 | name: QT_TR_NOOP("Mic") |
127 | 58 | value: trustStoreModel.count > 0 ? | 58 | caption: QT_TR_NOOP("Apps that have requested access to your mic") |
128 | 59 | i18n.tr("%1/%2").arg(trustStoreModel.grantedCount).arg(trustStoreModel.count) : | 59 | trustStoreService: "PulseAudio" |
129 | 60 | i18n.tr("0") | 60 | } |
130 | 61 | onClicked: pageStack.push(Qt.resolvedUrl("AppAccessControl.qml"), { | 61 | } |
131 | 62 | "title": i18n.tr(model.name), | 62 | |
132 | 63 | "caption": i18n.tr(model.caption), | 63 | Repeater { |
133 | 64 | "model": trustStoreModel, | 64 | model: appsModel |
134 | 65 | }) | 65 | |
135 | 66 | 66 | ListItem.SingleValue { | |
136 | 67 | TrustStoreModel { | 67 | text: model.name |
137 | 68 | id: trustStoreModel | 68 | enabled: trustStoreModel.count > 0 |
138 | 69 | serviceName: model.trustStoreService | 69 | value: trustStoreModel.count > 0 ? |
139 | 70 | i18n.tr("%1/%2").arg(trustStoreModel.grantedCount).arg(trustStoreModel.count) : | ||
140 | 71 | i18n.tr("0") | ||
141 | 72 | onClicked: pageStack.push(Qt.resolvedUrl("AppAccessControl.qml"), { | ||
142 | 73 | "title": i18n.tr(model.name), | ||
143 | 74 | "caption": i18n.tr(model.caption), | ||
144 | 75 | "model": trustStoreModel, | ||
145 | 76 | }) | ||
146 | 77 | |||
147 | 78 | TrustStoreModel { | ||
148 | 79 | id: trustStoreModel | ||
149 | 80 | serviceName: model.trustStoreService | ||
150 | 81 | } | ||
151 | 70 | } | 82 | } |
152 | 71 | } | 83 | } |
153 | 72 | } | 84 | } |
154 | 73 | 85 | ||
155 | === modified file 'plugins/security-privacy/AppAccessControl.qml' | |||
156 | --- plugins/security-privacy/AppAccessControl.qml 2014-08-15 12:54:13 +0000 | |||
157 | +++ plugins/security-privacy/AppAccessControl.qml 2015-07-16 14:21:51 +0000 | |||
158 | @@ -28,24 +28,36 @@ | |||
159 | 28 | property alias model: repeater.model | 28 | property alias model: repeater.model |
160 | 29 | property alias caption: captionLabel.text | 29 | property alias caption: captionLabel.text |
161 | 30 | 30 | ||
180 | 31 | Column { | 31 | Flickable { |
181 | 32 | anchors.left: parent.left | 32 | anchors.fill: parent |
182 | 33 | anchors.right: parent.right | 33 | contentHeight: contentItem.childrenRect.height |
183 | 34 | 34 | boundsBehavior: (contentHeight > root.height) ? | |
184 | 35 | ListItem.Caption { | 35 | Flickable.DragAndOvershootBounds : |
185 | 36 | id: captionLabel | 36 | Flickable.StopAtBounds |
186 | 37 | } | 37 | /* Set the direction to workaround |
187 | 38 | 38 | https://bugreports.qt-project.org/browse/QTBUG-31905 otherwise the UI | |
188 | 39 | Repeater { | 39 | might end up in a situation where scrolling doesn't work */ |
189 | 40 | id: repeater | 40 | flickableDirection: Flickable.VerticalFlick |
190 | 41 | 41 | ||
191 | 42 | ListItem.Standard { | 42 | Column { |
192 | 43 | text: model.applicationName | 43 | anchors.left: parent.left |
193 | 44 | iconSource: model.iconName | 44 | anchors.right: parent.right |
194 | 45 | control: Switch { | 45 | |
195 | 46 | id: welcomeStatsSwitch | 46 | ListItem.Caption { |
196 | 47 | checked: model.granted | 47 | id: captionLabel |
197 | 48 | onClicked: root.model.setEnabled(index, !model.granted) | 48 | } |
198 | 49 | |||
199 | 50 | Repeater { | ||
200 | 51 | id: repeater | ||
201 | 52 | |||
202 | 53 | ListItem.Standard { | ||
203 | 54 | text: model.applicationName | ||
204 | 55 | iconSource: model.iconName | ||
205 | 56 | control: Switch { | ||
206 | 57 | id: welcomeStatsSwitch | ||
207 | 58 | checked: model.granted | ||
208 | 59 | onClicked: root.model.setEnabled(index, !model.granted) | ||
209 | 60 | } | ||
210 | 49 | } | 61 | } |
211 | 50 | } | 62 | } |
212 | 51 | } | 63 | } |
213 | 52 | 64 | ||
214 | === modified file 'plugins/security-privacy/LockSecurity.qml' | |||
215 | --- plugins/security-privacy/LockSecurity.qml 2015-04-15 16:40:16 +0000 | |||
216 | +++ plugins/security-privacy/LockSecurity.qml 2015-07-16 14:21:51 +0000 | |||
217 | @@ -426,78 +426,90 @@ | |||
218 | 426 | } | 426 | } |
219 | 427 | } | 427 | } |
220 | 428 | 428 | ||
250 | 429 | Column { | 429 | Flickable { |
251 | 430 | anchors.left: parent.left | 430 | anchors.fill: parent |
252 | 431 | anchors.right: parent.right | 431 | contentHeight: contentItem.childrenRect.height |
253 | 432 | 432 | boundsBehavior: (contentHeight > page.height) ? | |
254 | 433 | SettingsItemTitle { | 433 | Flickable.DragAndOvershootBounds : |
255 | 434 | text: i18n.tr("Unlock the phone using:") | 434 | Flickable.StopAtBounds |
256 | 435 | } | 435 | /* Set the direction to workaround |
257 | 436 | 436 | https://bugreports.qt-project.org/browse/QTBUG-31905 otherwise the UI | |
258 | 437 | ListItem.ItemSelector { | 437 | might end up in a situation where scrolling doesn't work */ |
259 | 438 | property string swipe: i18n.tr("Swipe (no security)") | 438 | flickableDirection: Flickable.VerticalFlick |
260 | 439 | property string passcode: i18n.tr("4-digit passcode") | 439 | |
261 | 440 | property string passphrase: i18n.tr("Passphrase") | 440 | Column { |
262 | 441 | property string swipeAlt: i18n.tr("Swipe (no security)ā¦ ") | 441 | anchors.left: parent.left |
263 | 442 | property string passcodeAlt: i18n.tr("4-digit passcodeā¦") | 442 | anchors.right: parent.right |
264 | 443 | property string passphraseAlt: i18n.tr("Passphraseā¦") | 443 | |
265 | 444 | 444 | SettingsItemTitle { | |
266 | 445 | id: unlockMethod | 445 | text: i18n.tr("Unlock the phone using:") |
267 | 446 | model: 3 | 446 | } |
268 | 447 | delegate: OptionSelectorDelegate { | 447 | |
269 | 448 | objectName: { | 448 | ListItem.ItemSelector { |
270 | 449 | switch (index) { | 449 | property string swipe: i18n.tr("Swipe (no security)") |
271 | 450 | case 0: | 450 | property string passcode: i18n.tr("4-digit passcode") |
272 | 451 | return "method_swipe"; | 451 | property string passphrase: i18n.tr("Passphrase") |
273 | 452 | case 1: | 452 | property string swipeAlt: i18n.tr("Swipe (no security)ā¦ ") |
274 | 453 | return "method_code"; | 453 | property string passcodeAlt: i18n.tr("4-digit passcodeā¦") |
275 | 454 | case 2: | 454 | property string passphraseAlt: i18n.tr("Passphraseā¦") |
276 | 455 | return "method_phrase"; | 455 | |
277 | 456 | default: | 456 | id: unlockMethod |
278 | 457 | return "method_unknown"; | 457 | model: 3 |
279 | 458 | delegate: OptionSelectorDelegate { | ||
280 | 459 | objectName: { | ||
281 | 460 | switch (index) { | ||
282 | 461 | case 0: | ||
283 | 462 | return "method_swipe"; | ||
284 | 463 | case 1: | ||
285 | 464 | return "method_code"; | ||
286 | 465 | case 2: | ||
287 | 466 | return "method_phrase"; | ||
288 | 467 | default: | ||
289 | 468 | return "method_unknown"; | ||
290 | 469 | } | ||
291 | 458 | } | 470 | } |
334 | 459 | } | 471 | text: index == 0 ? (unlockMethod.selectedIndex == 0 ? unlockMethod.swipe : unlockMethod.swipeAlt) : |
335 | 460 | text: index == 0 ? (unlockMethod.selectedIndex == 0 ? unlockMethod.swipe : unlockMethod.swipeAlt) : | 472 | (index == 1 ? (unlockMethod.selectedIndex == 1 ? unlockMethod.passcode : unlockMethod.passcodeAlt) : |
336 | 461 | (index == 1 ? (unlockMethod.selectedIndex == 1 ? unlockMethod.passcode : unlockMethod.passcodeAlt) : | 473 | (unlockMethod.selectedIndex == 2 ? unlockMethod.passphrase : unlockMethod.passphraseAlt)) |
337 | 462 | (unlockMethod.selectedIndex == 2 ? unlockMethod.passphrase : unlockMethod.passphraseAlt)) | 474 | } |
338 | 463 | } | 475 | expanded: true |
339 | 464 | expanded: true | 476 | onDelegateClicked: { |
340 | 465 | onDelegateClicked: { | 477 | if (selectedIndex === index && !changeControl.visible) |
341 | 466 | if (selectedIndex === index && !changeControl.visible) | 478 | return // nothing to do |
342 | 467 | return // nothing to do | 479 | |
343 | 468 | 480 | selectedIndex = index | |
344 | 469 | selectedIndex = index | 481 | openDialog() |
345 | 470 | openDialog() | 482 | } |
346 | 471 | } | 483 | } |
347 | 472 | } | 484 | Binding { |
348 | 473 | Binding { | 485 | target: unlockMethod |
349 | 474 | target: unlockMethod | 486 | property: "selectedIndex" |
350 | 475 | property: "selectedIndex" | 487 | value: methodToIndex(securityPrivacy.securityType) |
351 | 476 | value: methodToIndex(securityPrivacy.securityType) | 488 | } |
352 | 477 | } | 489 | |
353 | 478 | 490 | ListItem.SingleControl { | |
354 | 479 | ListItem.SingleControl { | 491 | |
355 | 480 | 492 | id: changeControl | |
356 | 481 | id: changeControl | 493 | visible: securityPrivacy.securityType !== |
357 | 482 | visible: securityPrivacy.securityType !== | 494 | UbuntuSecurityPrivacyPanel.Swipe |
358 | 483 | UbuntuSecurityPrivacyPanel.Swipe | 495 | |
359 | 484 | 496 | control: Button { | |
360 | 485 | control: Button { | 497 | property string changePasscode: i18n.tr("Change passcodeā¦") |
361 | 486 | property string changePasscode: i18n.tr("Change passcodeā¦") | 498 | property string changePassphrase: i18n.tr("Change passphraseā¦") |
362 | 487 | property string changePassphrase: i18n.tr("Change passphraseā¦") | 499 | |
363 | 488 | 500 | property bool passcode: securityPrivacy.securityType === | |
364 | 489 | property bool passcode: securityPrivacy.securityType === | 501 | UbuntuSecurityPrivacyPanel.Passcode |
365 | 490 | UbuntuSecurityPrivacyPanel.Passcode | 502 | |
366 | 491 | 503 | objectName: "changePass" | |
367 | 492 | objectName: "changePass" | 504 | enabled: parent.visible |
368 | 493 | enabled: parent.visible | 505 | |
369 | 494 | 506 | text: passcode ? changePasscode : changePassphrase | |
370 | 495 | text: passcode ? changePasscode : changePassphrase | 507 | width: parent.width - units.gu(4) |
371 | 496 | width: parent.width - units.gu(4) | 508 | |
372 | 497 | 509 | onClicked: openDialog() | |
373 | 498 | onClicked: openDialog() | 510 | } |
374 | 499 | } | 511 | showDivider: false |
375 | 500 | showDivider: false | 512 | } |
376 | 501 | } | 513 | } |
377 | 502 | } | 514 | } |
378 | 503 | } | 515 | } |
379 | 504 | 516 | ||
380 | === modified file 'plugins/security-privacy/PhoneLocking.qml' | |||
381 | --- plugins/security-privacy/PhoneLocking.qml 2015-04-15 15:29:12 +0000 | |||
382 | +++ plugins/security-privacy/PhoneLocking.qml 2015-07-16 14:21:51 +0000 | |||
383 | @@ -37,106 +37,118 @@ | |||
384 | 37 | id: securityPrivacy | 37 | id: securityPrivacy |
385 | 38 | } | 38 | } |
386 | 39 | 39 | ||
487 | 40 | Column { | 40 | Flickable { |
488 | 41 | anchors.left: parent.left | 41 | anchors.fill: parent |
489 | 42 | anchors.right: parent.right | 42 | contentHeight: contentItem.childrenRect.height |
490 | 43 | 43 | boundsBehavior: (contentHeight > root.height) ? | |
491 | 44 | ListItem.SingleValue { | 44 | Flickable.DragAndOvershootBounds : |
492 | 45 | property string swipe: i18n.ctr("Unlock with swipe", "None") | 45 | Flickable.StopAtBounds |
493 | 46 | property string passcode: i18n.tr("Passcode") | 46 | /* Set the direction to workaround |
494 | 47 | property string passphrase: i18n.tr("Passphrase") | 47 | https://bugreports.qt-project.org/browse/QTBUG-31905 otherwise the UI |
495 | 48 | 48 | might end up in a situation where scrolling doesn't work */ | |
496 | 49 | objectName: "lockSecurity" | 49 | flickableDirection: Flickable.VerticalFlick |
497 | 50 | text: i18n.tr("Lock security") | 50 | |
498 | 51 | value: { | 51 | Column { |
499 | 52 | switch (securityPrivacy.securityType) { | 52 | anchors.left: parent.left |
500 | 53 | case UbuntuSecurityPrivacyPanel.Swipe: | 53 | anchors.right: parent.right |
501 | 54 | return swipe | 54 | |
502 | 55 | case UbuntuSecurityPrivacyPanel.Passcode: | 55 | ListItem.SingleValue { |
503 | 56 | return passcode | 56 | property string swipe: i18n.ctr("Unlock with swipe", "None") |
504 | 57 | case UbuntuSecurityPrivacyPanel.Passphrase: | 57 | property string passcode: i18n.tr("Passcode") |
505 | 58 | return passphrase | 58 | property string passphrase: i18n.tr("Passphrase") |
506 | 59 | } | 59 | |
507 | 60 | } | 60 | objectName: "lockSecurity" |
508 | 61 | progression: true | 61 | text: i18n.tr("Lock security") |
509 | 62 | onClicked: pageStack.push(Qt.resolvedUrl("LockSecurity.qml")) | 62 | value: { |
510 | 63 | } | 63 | switch (securityPrivacy.securityType) { |
511 | 64 | 64 | case UbuntuSecurityPrivacyPanel.Swipe: | |
512 | 65 | ListItem.SingleValue { | 65 | return swipe |
513 | 66 | objectName: "lockTimeout" | 66 | case UbuntuSecurityPrivacyPanel.Passcode: |
514 | 67 | property bool lockOnSuspend: securityPrivacy.securityType !== | 67 | return passcode |
515 | 68 | UbuntuSecurityPrivacyPanel.Swipe | 68 | case UbuntuSecurityPrivacyPanel.Passphrase: |
516 | 69 | text: lockOnSuspend ? i18n.tr("Lock when idle") | 69 | return passphrase |
517 | 70 | : i18n.tr("Sleep when idle") | 70 | } |
518 | 71 | value: { | 71 | } |
519 | 72 | if (usePowerd) { | 72 | progression: true |
520 | 73 | var timeout = Math.round(powerSettings.activityTimeout/60) | 73 | onClicked: pageStack.push(Qt.resolvedUrl("LockSecurity.qml")) |
521 | 74 | return (powerSettings.activityTimeout != 0) ? | 74 | } |
522 | 75 | // TRANSLATORS: %1 is the number of minutes | 75 | |
523 | 76 | i18n.tr("%1 minute", | 76 | ListItem.SingleValue { |
524 | 77 | "%1 minutes", | 77 | objectName: "lockTimeout" |
525 | 78 | timeout).arg(timeout) : | 78 | property bool lockOnSuspend: securityPrivacy.securityType !== |
526 | 79 | i18n.tr("Never") | 79 | UbuntuSecurityPrivacyPanel.Swipe |
527 | 80 | } | 80 | text: lockOnSuspend ? i18n.tr("Lock when idle") |
528 | 81 | else { | 81 | : i18n.tr("Sleep when idle") |
529 | 82 | var timeout = Math.round(powerSettings.idleDelay/60) | 82 | value: { |
530 | 83 | return (powerSettings.idleDelay != 0) ? | 83 | if (usePowerd) { |
531 | 84 | // TRANSLATORS: %1 is the number of minutes | 84 | var timeout = Math.round(powerSettings.activityTimeout/60) |
532 | 85 | i18n.tr("%1 minute", | 85 | return (powerSettings.activityTimeout != 0) ? |
533 | 86 | "%1 minutes", | 86 | // TRANSLATORS: %1 is the number of minutes |
534 | 87 | timeout).arg(timeout) : | 87 | i18n.tr("%1 minute", |
535 | 88 | i18n.tr("Never") | 88 | "%1 minutes", |
536 | 89 | } | 89 | timeout).arg(timeout) : |
537 | 90 | } | 90 | i18n.tr("Never") |
538 | 91 | progression: true | 91 | } |
539 | 92 | onClicked: | 92 | else { |
540 | 93 | pageStack.push( | 93 | var timeout = Math.round(powerSettings.idleDelay/60) |
541 | 94 | Qt.resolvedUrl("../battery/SleepValues.qml"), | 94 | return (powerSettings.idleDelay != 0) ? |
542 | 95 | { title: text, lockOnSuspend: lockOnSuspend } ) | 95 | // TRANSLATORS: %1 is the number of minutes |
543 | 96 | } | 96 | i18n.tr("%1 minute", |
544 | 97 | 97 | "%1 minutes", | |
545 | 98 | ListItem.Standard { | 98 | timeout).arg(timeout) : |
546 | 99 | control: CheckBox { | 99 | i18n.tr("Never") |
547 | 100 | checked: true | 100 | } |
548 | 101 | } | 101 | } |
549 | 102 | text: i18n.tr("Sleep locks immediately") | 102 | progression: true |
550 | 103 | visible: showAllUI | 103 | onClicked: |
551 | 104 | } | 104 | pageStack.push( |
552 | 105 | 105 | Qt.resolvedUrl("../battery/SleepValues.qml"), | |
553 | 106 | SettingsItemTitle { | 106 | { title: text, lockOnSuspend: lockOnSuspend } ) |
554 | 107 | text: i18n.tr("When locked, allow:") | 107 | } |
555 | 108 | } | 108 | |
556 | 109 | 109 | ListItem.Standard { | |
557 | 110 | ListItem.Standard { | 110 | control: CheckBox { |
558 | 111 | text: i18n.tr("Launcher") | 111 | checked: true |
559 | 112 | control: CheckBox { | 112 | } |
560 | 113 | id: launcherCheck | 113 | text: i18n.tr("Sleep locks immediately") |
561 | 114 | enabled: securityPrivacy.securityType !== UbuntuSecurityPrivacyPanel.Swipe | 114 | visible: showAllUI |
562 | 115 | 115 | } | |
563 | 116 | property bool serverChecked: securityPrivacy.enableLauncherWhileLocked || !enabled | 116 | |
564 | 117 | onServerCheckedChanged: checked = serverChecked | 117 | SettingsItemTitle { |
565 | 118 | Component.onCompleted: checked = serverChecked | 118 | text: i18n.tr("When locked, allow:") |
566 | 119 | onTriggered: securityPrivacy.enableLauncherWhileLocked = checked | 119 | } |
567 | 120 | } | 120 | |
568 | 121 | } | 121 | ListItem.Standard { |
569 | 122 | 122 | text: i18n.tr("Launcher") | |
570 | 123 | ListItem.Standard { | 123 | control: CheckBox { |
571 | 124 | text: i18n.tr("Notifications and quick settings") | 124 | id: launcherCheck |
572 | 125 | control: CheckBox { | 125 | enabled: securityPrivacy.securityType !== UbuntuSecurityPrivacyPanel.Swipe |
573 | 126 | id: indicatorsCheck | 126 | |
574 | 127 | enabled: securityPrivacy.securityType !== UbuntuSecurityPrivacyPanel.Swipe | 127 | property bool serverChecked: securityPrivacy.enableLauncherWhileLocked || !enabled |
575 | 128 | 128 | onServerCheckedChanged: checked = serverChecked | |
576 | 129 | property bool serverChecked: securityPrivacy.enableIndicatorsWhileLocked || !enabled | 129 | Component.onCompleted: checked = serverChecked |
577 | 130 | onServerCheckedChanged: checked = serverChecked | 130 | onTriggered: securityPrivacy.enableLauncherWhileLocked = checked |
578 | 131 | Component.onCompleted: checked = serverChecked | 131 | } |
579 | 132 | onTriggered: securityPrivacy.enableIndicatorsWhileLocked = checked | 132 | } |
580 | 133 | } | 133 | |
581 | 134 | } | 134 | ListItem.Standard { |
582 | 135 | 135 | text: i18n.tr("Notifications and quick settings") | |
583 | 136 | ListItem.Caption { | 136 | control: CheckBox { |
584 | 137 | text: securityPrivacy.securityType === UbuntuSecurityPrivacyPanel.Swipe ? | 137 | id: indicatorsCheck |
585 | 138 | i18n.tr("Turn on lock security to restrict access when the phone is locked.") : | 138 | enabled: securityPrivacy.securityType !== UbuntuSecurityPrivacyPanel.Swipe |
586 | 139 | i18n.tr("Other apps and functions will prompt you to unlock.") | 139 | |
587 | 140 | property bool serverChecked: securityPrivacy.enableIndicatorsWhileLocked || !enabled | ||
588 | 141 | onServerCheckedChanged: checked = serverChecked | ||
589 | 142 | Component.onCompleted: checked = serverChecked | ||
590 | 143 | onTriggered: securityPrivacy.enableIndicatorsWhileLocked = checked | ||
591 | 144 | } | ||
592 | 145 | } | ||
593 | 146 | |||
594 | 147 | ListItem.Caption { | ||
595 | 148 | text: securityPrivacy.securityType === UbuntuSecurityPrivacyPanel.Swipe ? | ||
596 | 149 | i18n.tr("Turn on lock security to restrict access when the phone is locked.") : | ||
597 | 150 | i18n.tr("Other apps and functions will prompt you to unlock.") | ||
598 | 151 | } | ||
599 | 140 | } | 152 | } |
600 | 141 | } | 153 | } |
601 | 142 | } | 154 | } |
602 | 143 | 155 | ||
603 | === modified file 'plugins/security-privacy/SimPin.qml' | |||
604 | --- plugins/security-privacy/SimPin.qml 2015-04-01 18:25:32 +0000 | |||
605 | +++ plugins/security-privacy/SimPin.qml 2015-07-16 14:21:51 +0000 | |||
606 | @@ -345,96 +345,108 @@ | |||
607 | 345 | } | 345 | } |
608 | 346 | } | 346 | } |
609 | 347 | 347 | ||
700 | 348 | Column { | 348 | Flickable { |
701 | 349 | anchors.left: parent.left | 349 | anchors.fill: parent |
702 | 350 | anchors.right: parent.right | 350 | contentHeight: contentItem.childrenRect.height |
703 | 351 | 351 | boundsBehavior: (contentHeight > root.height) ? | |
704 | 352 | Repeater { | 352 | Flickable.DragAndOvershootBounds : |
705 | 353 | model: sims.length | 353 | Flickable.StopAtBounds |
706 | 354 | Column { | 354 | /* Set the direction to workaround |
707 | 355 | id: sim | 355 | https://bugreports.qt-project.org/browse/QTBUG-31905 otherwise the UI |
708 | 356 | anchors { | 356 | might end up in a situation where scrolling doesn't work */ |
709 | 357 | left: parent.left | 357 | flickableDirection: Flickable.VerticalFlick |
710 | 358 | right: parent.right | 358 | |
711 | 359 | } | 359 | Column { |
712 | 360 | 360 | anchors.left: parent.left | |
713 | 361 | states: [ | 361 | anchors.right: parent.right |
714 | 362 | StateĀ { | 362 | |
715 | 363 | name: "locked" | 363 | Repeater { |
716 | 364 | when: sims[index].simMng.pinRequired !== OfonoSimManager.NoPin | 364 | model: sims.length |
717 | 365 | }, | 365 | Column { |
718 | 366 | StateĀ { | 366 | id: sim |
719 | 367 | name: "unlocked" | 367 | anchors { |
720 | 368 | when: sims[index].simMng.pinRequired === OfonoSimManager.NoPin | 368 | left: parent.left |
721 | 369 | } | 369 | right: parent.right |
722 | 370 | ] | 370 | } |
723 | 371 | 371 | ||
724 | 372 | Connections { | 372 | states: [ |
725 | 373 | target: sims[index].simMng | 373 | StateĀ { |
726 | 374 | onLockedPinsChanged: { | 374 | name: "locked" |
727 | 375 | simPinSwitch.checked = | 375 | when: sims[index].simMng.pinRequired !== OfonoSimManager.NoPin |
728 | 376 | sims[index].simMng.lockedPins.length > 0; | 376 | }, |
729 | 377 | } | 377 | StateĀ { |
730 | 378 | } | 378 | name: "unlocked" |
731 | 379 | 379 | when: sims[index].simMng.pinRequired === OfonoSimManager.NoPin | |
732 | 380 | ListItem.Standard { | 380 | } |
733 | 381 | text: sims[index].title | 381 | ] |
734 | 382 | visible: sims.length > 1 | 382 | |
735 | 383 | } | 383 | Connections { |
736 | 384 | 384 | target: sims[index].simMng | |
737 | 385 | ListItem.Standard { | 385 | onLockedPinsChanged: { |
738 | 386 | text: i18n.tr("SIM PIN") | 386 | simPinSwitch.checked = |
739 | 387 | control: Switch { | 387 | sims[index].simMng.lockedPins.length > 0; |
740 | 388 | id: simPinSwitch | 388 | } |
741 | 389 | objectName: "simPinSwitch" | 389 | } |
742 | 390 | checked: sims[index].simMng.lockedPins.length > 0 | 390 | |
743 | 391 | onClicked: { | 391 | ListItem.Standard { |
744 | 392 | curSim = sims[index].simMng; | 392 | text: sims[index].title |
745 | 393 | PopupUtils.open(lockDialogComponent, simPinSwitch); | 393 | visible: sims.length > 1 |
746 | 394 | } | 394 | } |
747 | 395 | } | 395 | |
748 | 396 | } | 396 | ListItem.Standard { |
749 | 397 | 397 | text: i18n.tr("SIM PIN") | |
750 | 398 | ListItem.Standard { | 398 | control: Switch { |
751 | 399 | id: changeControl | 399 | id: simPinSwitch |
752 | 400 | visible: sim.state === "unlocked" | 400 | objectName: "simPinSwitch" |
753 | 401 | text: i18n.tr("Unlocked") | 401 | checked: sims[index].simMng.lockedPins.length > 0 |
754 | 402 | control: Button { | 402 | onClicked: { |
755 | 403 | enabled: parent.visible | 403 | curSim = sims[index].simMng; |
756 | 404 | text: i18n.tr("Change PINā¦") | 404 | PopupUtils.open(lockDialogComponent, simPinSwitch); |
757 | 405 | onClicked: { | 405 | } |
758 | 406 | curSim = sims[index].simMng; | 406 | } |
759 | 407 | PopupUtils.open(dialogComponent); | 407 | } |
760 | 408 | } | 408 | |
761 | 409 | } | 409 | ListItem.Standard { |
762 | 410 | } | 410 | id: changeControl |
763 | 411 | 411 | visible: sim.state === "unlocked" | |
764 | 412 | ListItem.Standard { | 412 | text: i18n.tr("Unlocked") |
765 | 413 | id: lockControl | 413 | control: Button { |
766 | 414 | visible: sim.state === "locked" | 414 | enabled: parent.visible |
767 | 415 | text: i18n.tr("Locked") | 415 | text: i18n.tr("Change PINā¦") |
768 | 416 | control: Button { | 416 | onClicked: { |
769 | 417 | objectName: "unlock" | 417 | curSim = sims[index].simMng; |
770 | 418 | enabled: sims[index].simMng.pinRequired !== 'none' | 418 | PopupUtils.open(dialogComponent); |
771 | 419 | text: i18n.tr("Unlockā¦") | 419 | } |
772 | 420 | color: UbuntuColors.green | 420 | } |
773 | 421 | onClicked: Connectivity.unlockModem(sims[index].path) | 421 | } |
774 | 422 | } | 422 | |
775 | 423 | } | 423 | ListItem.Standard { |
776 | 424 | 424 | id: lockControl | |
777 | 425 | ListItem.Divider { | 425 | visible: sim.state === "locked" |
778 | 426 | visible: index < (sims.length - 1) | 426 | text: i18n.tr("Locked") |
779 | 427 | } | 427 | control: Button { |
780 | 428 | 428 | objectName: "unlock" | |
781 | 429 | } | 429 | enabled: sims[index].simMng.pinRequired !== 'none' |
782 | 430 | } | 430 | text: i18n.tr("Unlockā¦") |
783 | 431 | 431 | color: UbuntuColors.green | |
784 | 432 | ListItem.Caption { | 432 | onClicked: Connectivity.unlockModem(sims[index].path) |
785 | 433 | text: i18n.tr("When a SIM PIN is set, it must be entered to access cellular services after restarting the phone or swapping the SIM.") | 433 | } |
786 | 434 | } | 434 | } |
787 | 435 | 435 | ||
788 | 436 | ListItem.Caption { | 436 | ListItem.Divider { |
789 | 437 | text: i18n.tr("Entering an incorrect PIN repeatedly may lock the SIM permanently.") | 437 | visible: index < (sims.length - 1) |
790 | 438 | } | ||
791 | 439 | |||
792 | 440 | } | ||
793 | 441 | } | ||
794 | 442 | |||
795 | 443 | ListItem.Caption { | ||
796 | 444 | text: i18n.tr("When a SIM PIN is set, it must be entered to access cellular services after restarting the phone or swapping the SIM.") | ||
797 | 445 | } | ||
798 | 446 | |||
799 | 447 | ListItem.Caption { | ||
800 | 448 | text: i18n.tr("Entering an incorrect PIN repeatedly may lock the SIM permanently.") | ||
801 | 449 | } | ||
802 | 438 | } | 450 | } |
803 | 439 | } | 451 | } |
804 | 440 | } | 452 | } |
805 | 441 | 453 | ||
806 | === modified file 'plugins/security-privacy/diagnostics/PageComponent.qml' | |||
807 | --- plugins/security-privacy/diagnostics/PageComponent.qml 2013-07-29 15:04:03 +0000 | |||
808 | +++ plugins/security-privacy/diagnostics/PageComponent.qml 2015-07-16 14:21:51 +0000 | |||
809 | @@ -37,11 +37,18 @@ | |||
810 | 37 | } | 37 | } |
811 | 38 | onReportCrashesChanged: maybeUpdate() | 38 | onReportCrashesChanged: maybeUpdate() |
812 | 39 | } | 39 | } |
813 | 40 | |||
814 | 40 | Flickable { | 41 | Flickable { |
815 | 41 | id: scrollWidget | 42 | id: scrollWidget |
816 | 42 | anchors.fill: parent | 43 | anchors.fill: parent |
817 | 43 | contentHeight: contentItem.childrenRect.height | 44 | contentHeight: contentItem.childrenRect.height |
819 | 44 | boundsBehavior: Flickable.StopAtBounds | 45 | boundsBehavior: (contentHeight > root.height) ? |
820 | 46 | Flickable.DragAndOvershootBounds : | ||
821 | 47 | Flickable.StopAtBounds | ||
822 | 48 | /* Set the direction to workaround | ||
823 | 49 | https://bugreports.qt-project.org/browse/QTBUG-31905 otherwise the UI | ||
824 | 50 | might end up in a situation where scrolling doesn't work */ | ||
825 | 51 | flickableDirection: Flickable.VerticalFlick | ||
826 | 45 | 52 | ||
827 | 46 | Column { | 53 | Column { |
828 | 47 | anchors.left: parent.left | 54 | anchors.left: parent.left |
829 | 48 | 55 | ||
830 | === modified file 'plugins/wifi/NetworkDetails.qml' | |||
831 | --- plugins/wifi/NetworkDetails.qml 2015-01-20 14:11:24 +0000 | |||
832 | +++ plugins/wifi/NetworkDetails.qml 2015-07-16 14:21:51 +0000 | |||
833 | @@ -37,63 +37,76 @@ | |||
834 | 37 | 37 | ||
835 | 38 | title: i18n.tr("Network details") | 38 | title: i18n.tr("Network details") |
836 | 39 | 39 | ||
839 | 40 | Column { | 40 | Flickable { |
838 | 41 | |||
840 | 42 | anchors.fill: parent | 41 | anchors.fill: parent |
895 | 43 | 42 | contentHeight: contentItem.childrenRect.height | |
896 | 44 | ListItem.Standard { | 43 | boundsBehavior: (contentHeight > networkDetails.height) ? |
897 | 45 | text: i18n.tr("Name") | 44 | Flickable.DragAndOvershootBounds : |
898 | 46 | control: Label { | 45 | Flickable.StopAtBounds |
899 | 47 | text: networkName | 46 | /* Set the direction to workaround |
900 | 48 | } | 47 | https://bugreports.qt-project.org/browse/QTBUG-31905 otherwise the UI |
901 | 49 | } | 48 | might end up in a situation where scrolling doesn't work */ |
902 | 50 | 49 | flickableDirection: Flickable.VerticalFlick | |
903 | 51 | ListItem.Standard { | 50 | |
904 | 52 | id: lastLabel | 51 | Column { |
905 | 53 | text: i18n.tr("Last connected") | 52 | |
906 | 54 | control: Label { | 53 | anchors.left: parent.left |
907 | 55 | id: lastField | 54 | anchors.right: parent.right |
908 | 56 | 55 | ||
909 | 57 | text: networkDetails.lastUsed.length !== 0 ? | 56 | ListItem.Standard { |
910 | 58 | networkDetails.lastUsed : i18n.tr("Never") | 57 | text: i18n.tr("Name") |
911 | 59 | } | 58 | control: Label { |
912 | 60 | } | 59 | text: networkName |
913 | 61 | 60 | } | |
914 | 62 | ListItem.Standard { | 61 | } |
915 | 63 | id: passwordLabel | 62 | |
916 | 64 | text: i18n.tr("Password") | 63 | ListItem.Standard { |
917 | 65 | visible: networkDetails.password.length !== 0 | 64 | id: lastLabel |
918 | 66 | control: TextInput { | 65 | text: i18n.tr("Last connected") |
919 | 67 | id: passwordField | 66 | control: Label { |
920 | 68 | readOnly: true | 67 | id: lastField |
921 | 69 | text: networkDetails.password | 68 | |
922 | 70 | echoMode: passwordVisibleSwitch.checked ? | 69 | text: networkDetails.lastUsed.length !== 0 ? |
923 | 71 | TextInput.Normal : TextInput.Password | 70 | networkDetails.lastUsed : i18n.tr("Never") |
924 | 72 | } | 71 | } |
925 | 73 | } | 72 | } |
926 | 74 | 73 | ||
927 | 75 | ListItem.Standard { | 74 | ListItem.Standard { |
928 | 76 | id: passwordVisible | 75 | id: passwordLabel |
929 | 77 | text: i18n.tr("Show password") | 76 | text: i18n.tr("Password") |
930 | 78 | visible: networkDetails.password.length !== 0 | 77 | visible: networkDetails.password.length !== 0 |
931 | 79 | control: Switch { | 78 | control: TextInput { |
932 | 80 | id: passwordVisibleSwitch | 79 | id: passwordField |
933 | 81 | } | 80 | readOnly: true |
934 | 82 | } | 81 | text: networkDetails.password |
935 | 83 | 82 | echoMode: passwordVisibleSwitch.checked ? | |
936 | 84 | ListItem.Divider {} | 83 | TextInput.Normal : TextInput.Password |
937 | 85 | 84 | } | |
938 | 86 | Button { | 85 | } |
939 | 87 | objectName: "forgetNetwork" | 86 | |
940 | 88 | text : i18n.tr("Forget this network") | 87 | ListItem.Standard { |
941 | 89 | anchors { | 88 | id: passwordVisible |
942 | 90 | left: parent.left | 89 | text: i18n.tr("Show password") |
943 | 91 | right: parent.right | 90 | visible: networkDetails.password.length !== 0 |
944 | 92 | margins: units.gu(2) | 91 | control: Switch { |
945 | 93 | } | 92 | id: passwordVisibleSwitch |
946 | 94 | onClicked : { | 93 | } |
947 | 95 | DbusHelper.forgetConnection(dbusPath); | 94 | } |
948 | 96 | pageStack.pop(); | 95 | |
949 | 96 | ListItem.Divider {} | ||
950 | 97 | |||
951 | 98 | Button { | ||
952 | 99 | objectName: "forgetNetwork" | ||
953 | 100 | text : i18n.tr("Forget this network") | ||
954 | 101 | anchors { | ||
955 | 102 | left: parent.left | ||
956 | 103 | right: parent.right | ||
957 | 104 | margins: units.gu(2) | ||
958 | 105 | } | ||
959 | 106 | onClicked : { | ||
960 | 107 | DbusHelper.forgetConnection(dbusPath); | ||
961 | 108 | pageStack.pop(); | ||
962 | 109 | } | ||
963 | 97 | } | 110 | } |
964 | 98 | } | 111 | } |
965 | 99 | } | 112 | } |
966 | 100 | 113 | ||
967 | === modified file 'plugins/wifi/NetworkDetailsBrief.qml' | |||
968 | --- plugins/wifi/NetworkDetailsBrief.qml 2015-01-20 14:11:24 +0000 | |||
969 | +++ plugins/wifi/NetworkDetailsBrief.qml 2015-07-16 14:21:51 +0000 | |||
970 | @@ -26,53 +26,65 @@ | |||
971 | 26 | import Ubuntu.SystemSettings.Wifi 1.0 | 26 | import Ubuntu.SystemSettings.Wifi 1.0 |
972 | 27 | 27 | ||
973 | 28 | ItemPage { | 28 | ItemPage { |
975 | 29 | 29 | id: root | |
976 | 30 | property string networkName | 30 | property string networkName |
977 | 31 | property var accessPoint | 31 | property var accessPoint |
978 | 32 | 32 | ||
979 | 33 | title: networkName | 33 | title: networkName |
980 | 34 | 34 | ||
983 | 35 | Column { | 35 | Flickable { |
982 | 36 | |||
984 | 37 | anchors.fill: parent | 36 | anchors.fill: parent |
1023 | 38 | 37 | contentHeight: contentItem.childrenRect.height | |
1024 | 39 | ListItem.Divider {} | 38 | boundsBehavior: (contentHeight > root.height) ? |
1025 | 40 | 39 | Flickable.DragAndOvershootBounds : | |
1026 | 41 | Button { | 40 | Flickable.StopAtBounds |
1027 | 42 | text : i18n.tr("Forget this network") | 41 | /* Set the direction to workaround |
1028 | 43 | anchors { | 42 | https://bugreports.qt-project.org/browse/QTBUG-31905 otherwise the UI |
1029 | 44 | left: parent.left | 43 | might end up in a situation where scrolling doesn't work */ |
1030 | 45 | right: parent.right | 44 | flickableDirection: Flickable.VerticalFlick |
1031 | 46 | margins: units.gu(2) | 45 | |
1032 | 47 | } | 46 | Column { |
1033 | 48 | onClicked: { | 47 | |
1034 | 49 | if (DbusHelper.forgetActiveDevice()) { | 48 | anchors.left: parent.left |
1035 | 50 | accessPoint.checked = false; | 49 | anchors.right: parent.right |
1036 | 51 | accessPoint.checkedChanged(false) | 50 | |
1037 | 52 | } | 51 | ListItem.Divider {} |
1038 | 53 | 52 | ||
1039 | 54 | } | 53 | Button { |
1040 | 55 | } | 54 | text : i18n.tr("Forget this network") |
1041 | 56 | 55 | anchors { | |
1042 | 57 | ListItem.Standard { | 56 | left: parent.left |
1043 | 58 | text: i18n.tr("IP address") | 57 | right: parent.right |
1044 | 59 | id: addressItem | 58 | margins: units.gu(2) |
1045 | 60 | control: TextField { | 59 | } |
1046 | 61 | text: DbusHelper.wifiIp4Address | 60 | onClicked: { |
1047 | 62 | readOnly: true | 61 | if (DbusHelper.forgetActiveDevice()) { |
1048 | 63 | horizontalAlignment: TextInput.AlignRight | 62 | accessPoint.checked = false; |
1049 | 64 | width: addressItem.width/2 | 63 | accessPoint.checkedChanged(false) |
1050 | 65 | persistentSelection: true | 64 | } |
1051 | 66 | font.pixelSize: units.dp(16) | 65 | } |
1052 | 67 | font.weight: Font.Light | 66 | } |
1053 | 68 | font.family: "Ubuntu" | 67 | |
1054 | 69 | color: "#AAAAAA" | 68 | ListItem.Standard { |
1055 | 70 | maximumLength: 20 | 69 | text: i18n.tr("IP address") |
1056 | 71 | focus: true | 70 | id: addressItem |
1057 | 72 | clip: true | 71 | control: TextField { |
1058 | 73 | opacity: 0.9 | 72 | text: DbusHelper.wifiIp4Address |
1059 | 74 | cursorVisible: false | 73 | readOnly: true |
1060 | 75 | hasClearButton: false | 74 | horizontalAlignment: TextInput.AlignRight |
1061 | 75 | width: addressItem.width/2 | ||
1062 | 76 | persistentSelection: true | ||
1063 | 77 | font.pixelSize: units.dp(16) | ||
1064 | 78 | font.weight: Font.Light | ||
1065 | 79 | font.family: "Ubuntu" | ||
1066 | 80 | color: "#AAAAAA" | ||
1067 | 81 | maximumLength: 20 | ||
1068 | 82 | focus: true | ||
1069 | 83 | clip: true | ||
1070 | 84 | opacity: 0.9 | ||
1071 | 85 | cursorVisible: false | ||
1072 | 86 | hasClearButton: false | ||
1073 | 87 | } | ||
1074 | 76 | } | 88 | } |
1075 | 77 | } | 89 | } |
1076 | 78 | } | 90 | } |
Thanks, looks fine but could we split out the UI changes in another merge request? they are different logical units and it doesn't make sense to batch them together... (or at minimum update the commit message to describe the other changes, but it would still be good to have different commits)