~jonas-drange/ubuntu-system-settings/filepicker

« back to all changes in this revision

Viewing changes to plugins/security-privacy/SimPin.qml

  • Committer: Jonas G. Drange
  • Date: 2016-10-14 13:59:02 UTC
  • mfrom: (1673.1.55 ubuntu-system-settings)
  • Revision ID: jonas.drange@canonical.com-20161014135902-9xufvqt524iaurit
sync trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*
2
 
 * Copyright (C) 2014 Canonical Ltd.
 
2
 * Copyright (C) 2014-2016 Canonical Ltd.
3
3
 *
4
4
 * This program is free software: you can redistribute it and/or modify it
5
5
 * under the terms of the GNU General Public License version 3, as published
19
19
 */
20
20
 
21
21
import GSettings 1.0
 
22
import MeeGo.QOfono 0.2
22
23
import QtQuick 2.4
23
24
import QtQuick.Layouts 1.1
 
25
import SystemSettings 1.0
 
26
import SystemSettings.ListItems 1.0 as SettingsListItems
24
27
import Ubuntu.Components 1.3
25
 
import Ubuntu.Components.ListItems 1.3 as ListItem
 
28
import Ubuntu.Components.ListItems 1.3 as ListItems
26
29
import Ubuntu.Components.Popups 1.3
27
 
import SystemSettings 1.0
28
30
import Ubuntu.SystemSettings.SecurityPrivacy 1.0
29
 
import MeeGo.QOfono 0.2
30
31
import "sims.js" as Sims
31
32
 
32
33
 
386
387
                        }
387
388
                    }
388
389
 
389
 
                    ListItem.Standard {
 
390
                    SettingsListItems.Standard {
390
391
                        text: sims[index].title
391
392
                        visible: sims.length > 1
392
393
                    }
393
394
 
394
 
                    ListItem.Standard {
 
395
                    SettingsListItems.Standard {
395
396
                        text: i18n.tr("SIM PIN")
396
 
                        control: Switch {
 
397
                        Switch {
397
398
                            id: simPinSwitch
398
399
                            objectName: "simPinSwitch"
399
400
                            checked: sims[index].simMng.lockedPins.length > 0
404
405
                        }
405
406
                    }
406
407
 
407
 
                    ListItem.Standard {
 
408
                    SettingsListItems.Standard {
408
409
                        id: changeControl
409
410
                        visible: sim.state === "unlocked"
410
411
                        text: i18n.tr("Unlocked")
411
 
                        control: Button {
 
412
                         Button {
412
413
                            enabled: parent.visible
413
414
                            text: i18n.tr("Change PIN…")
414
415
                            onClicked: {
418
419
                        }
419
420
                    }
420
421
 
421
 
                    ListItem.Standard {
 
422
                    SettingsListItems.Standard {
422
423
                        id: lockControl
423
424
                        visible: sim.state === "locked"
424
425
                        text: i18n.tr("Locked")
425
 
                        control: Button {
 
426
                        Button {
426
427
                            objectName: "unlock"
427
428
                            enabled: sims[index].simMng.pinRequired !== 'none'
428
429
                            text: i18n.tr("Unlock…")
431
432
                        }
432
433
                    }
433
434
 
434
 
                    ListItem.Divider {
 
435
                    ListItems.Divider {
435
436
                        visible: index < (sims.length - 1)
436
437
                    }
437
438
 
438
439
                }
439
440
            }
440
441
 
441
 
            ListItem.Caption {
 
442
            ListItems.Caption {
442
443
                text: i18n.tr("When a SIM PIN is set, it must be entered to access cellular services after restarting the device or swapping the SIM.")
443
444
            }
444
445
 
445
 
            ListItem.Caption {
 
446
            ListItems.Caption {
446
447
                text: i18n.tr("Entering an incorrect PIN repeatedly may lock the SIM permanently.")
447
448
            }
448
449
        }