[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [plasma-mobile/mart/activity-encryption] shell/activityconfiguration/package/contents/ui: working en
From:       Marco Martin <notmart () gmail ! com>
Date:       2012-01-16 17:09:11
Message-ID: 20120116170911.AF28FA60A6 () git ! kde ! org
[Download RAW message or body]

Git commit 43e142a814cf4aaf99784a45198c7f0e9b0a02e4 by Marco Martin.
Committed on 16/01/2012 at 18:08.
Pushed by mart into branch 'mart/activity-encryption'.

working encrypt ui

M  +19   -2    shell/activityconfiguration/package/contents/ui/view.qml

http://commits.kde.org/plasma-mobile/43e142a814cf4aaf99784a45198c7f0e9b0a02e4

diff --git a/shell/activityconfiguration/package/contents/ui/view.qml \
b/shell/activityconfiguration/package/contents/ui/view.qml index c866d94..60bebf5 \
                100644
--- a/shell/activityconfiguration/package/contents/ui/view.qml
+++ b/shell/activityconfiguration/package/contents/ui/view.qml
@@ -46,6 +46,11 @@ MobileComponents.Sheet {
         }
         configInterface.activityName = activityNameEdit.text
         configInterface.wallpaperIndex = wallpapersList.currentIndex
+
+        var service = activitySource.serviceForSource(configInterface.activityId)
+        var operation = service.operationDescription("setEncrypted")
+        operation["Encrypted"] = encryptedSwitch.checked
+        service.startOperationCall(operation)
     }
 
     onAccepted: {
@@ -73,6 +78,7 @@ MobileComponents.Sheet {
             for (var i in data) {
                 if (data[i]["Current"]) {
                     currentActivity = data[i]["Name"]
+                    encryptedSwitch.checked = activitySource.data[i]["Encrypted"]
                 }
                // if (1||!data[i]["Current"]) {
                     names.push(data[i]["Name"])
@@ -94,17 +100,20 @@ MobileComponents.Sheet {
     }
 
     content: [
-        Row {
+        Grid {
             id: nameRow
+            columns: 2
+            rows: 2
             anchors {
                 horizontalCenter: parent.horizontalCenter
                 top: parent.topMargin
             }
             visible: configInterface.activityNameConfigurable
-            Text {
+            PlasmaComponents.Label {
                 color: theme.textColor
                 text: i18n("Activity name:")
                 anchors.verticalCenter: activityNameEdit.verticalCenter
+                anchors.right: activityNameEdit.left
             }
             PlasmaComponents.TextField {
                 id: activityNameEdit
@@ -115,6 +124,14 @@ MobileComponents.Sheet {
                     accept()
                 }
             }
+            PlasmaComponents.Label {
+                color: theme.textColor
+                text: i18n("Encrypted:")
+                anchors.right: encryptedSwitch.left
+            }
+            PlasmaComponents.Switch {
+                id: encryptedSwitch
+            }
         },
         PlasmaComponents.Label {
             anchors {


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic