summaryrefslogtreecommitdiffstats
path: root/accounts/maildir/package
diff options
context:
space:
mode:
Diffstat (limited to 'accounts/maildir/package')
-rw-r--r--accounts/maildir/package/contents/ui/MaildirAccountSettings.qml37
1 files changed, 20 insertions, 17 deletions
diff --git a/accounts/maildir/package/contents/ui/MaildirAccountSettings.qml b/accounts/maildir/package/contents/ui/MaildirAccountSettings.qml
index 99814a06..189089fa 100644
--- a/accounts/maildir/package/contents/ui/MaildirAccountSettings.qml
+++ b/accounts/maildir/package/contents/ui/MaildirAccountSettings.qml
@@ -21,7 +21,7 @@ import QtQuick.Layouts 1.1
21 21
22import org.kube.framework.settings 1.0 as KubeSettings 22import org.kube.framework.settings 1.0 as KubeSettings
23import org.kube.framework.theme 1.0 23import org.kube.framework.theme 1.0
24import org.kde.kube.accounts.maildir 1.0 as MaildirAccount 24import org.kube.accounts.maildir 1.0 as MaildirAccount
25 25
26 26
27Rectangle { 27Rectangle {
@@ -47,6 +47,8 @@ Rectangle {
47 id: path 47 id: path
48 placeholderText: "path" 48 placeholderText: "path"
49 Layout.fillWidth: true 49 Layout.fillWidth: true
50 text: maildirSettings.path
51 onTextChanged: { maildirSettings.path = text; }
50 } 52 }
51 53
52 Text { 54 Text {
@@ -60,6 +62,8 @@ Rectangle {
60 id: username 62 id: username
61 placeholderText: "username" 63 placeholderText: "username"
62 Layout.fillWidth: true 64 Layout.fillWidth: true
65 text: transportSettings.username
66 onTextChanged: { transportSettings.username = text; }
63 } 67 }
64 68
65 Label { text: "Password" } 69 Label { text: "Password" }
@@ -67,6 +71,8 @@ Rectangle {
67 id: password 71 id: password
68 placeholderText: "password" 72 placeholderText: "password"
69 Layout.fillWidth: true 73 Layout.fillWidth: true
74 text: transportSettings.password
75 onTextChanged: { transportSettings.password = text; }
70 } 76 }
71 77
72 Label { text: "Server" } 78 Label { text: "Server" }
@@ -74,39 +80,36 @@ Rectangle {
74 id: server 80 id: server
75 placeholderText: "server" 81 placeholderText: "server"
76 Layout.fillWidth: true 82 Layout.fillWidth: true
83 text: transportSettings.server
84 onTextChanged: { transportSettings.server = text; }
77 } 85 }
78 86
79 MaildirAccount.MaildirSettings { 87 MaildirAccount.MaildirSettings {
80 id: maildirSettings 88 id: maildirSettings
81 identifier: "org.kde.maildir.instance1" 89 accountIdentifier: accountId
82 property alias path: path.text
83 } 90 }
84 91
85 KubeSettings.Settings { 92 KubeSettings.Settings {
86 id: accountSettings
87 identifier: "account." + accountId
88 property string primaryIdentity: "current"
89 }
90 KubeSettings.Settings {
91 id: identitySettings
92 identifier: "identity.current"
93 property string transport: "current"
94 }
95 KubeSettings.Settings {
96 id: transportSettings 93 id: transportSettings
94 //TODO set a proper identifier
97 identifier: "transport.current" 95 identifier: "transport.current"
98 property alias username: username.text 96 property string server;
99 property alias password: password.text 97 property string username;
100 property alias server: server.text 98 property string password;
101 } 99 }
102 100
103 Button { 101 Button {
104 id: button
105 text: "Save" 102 text: "Save"
106 onClicked: { 103 onClicked: {
107 transportSettings.save(); 104 transportSettings.save();
108 maildirSettings.save(); 105 maildirSettings.save();
109 } 106 }
110 } 107 }
108 Button {
109 text: "Remove"
110 onClicked: {
111 maildirSettings.remove();
112 }
113 }
111 } 114 }
112} 115}