summaryrefslogtreecommitdiffstats
path: root/components
diff options
context:
space:
mode:
authorChristian Mollekopf <chrigi_1@fastmail.fm>2017-04-16 17:47:48 +0200
committerChristian Mollekopf <chrigi_1@fastmail.fm>2017-04-16 17:47:48 +0200
commitef8a9f2f1d9f91358541b83fab63603aa3001bff (patch)
tree205a945c83a5029c7f700c0cb9c682a99fba30b2 /components
parent899ca952964a09bf2c2304b42d2ce0d859c99c39 (diff)
downloadkube-ef8a9f2f1d9f91358541b83fab63603aa3001bff.tar.gz
kube-ef8a9f2f1d9f91358541b83fab63603aa3001bff.zip
Don't thread drafts and sent
To do this we: * Expose from the model wether or not the model is threaded * Set the relevant properties from the model on the controller (so we can switch between aggregate and non-aggregate versions) * Keep the controller in the view it belongs to. While this works it highlights a couple of issues: * Controllers are view specific and should be kept within the view. * The actions we execute in the controller are closely related to the model. The model is essentially what the user sees, and therefore what he operatees on. * Sink should perhaps expose aggregates better. We have to pass around the values from the model because the model dispatches between aggregate and non-aggregate property depending on the threaded state. Similary the controller operates on the thread or not depending on the threaded state. Perhaps it would be more useful if sink actually returned the aggregate somehow, with the regular properties. That way the controller could use the regular properties from the entity it gets (which would simply either be the aggregate or non-aggregate depending on the executed query). If the aggregate already contains all matched ids, then we would also not have to execute an additional query to get the thread again, the modification would simply be applied to all ids originally returned.
Diffstat (limited to 'components')
-rw-r--r--components/kube/contents/ui/Kube.qml22
1 files changed, 0 insertions, 22 deletions
diff --git a/components/kube/contents/ui/Kube.qml b/components/kube/contents/ui/Kube.qml
index 41e970c6..979f7bd5 100644
--- a/components/kube/contents/ui/Kube.qml
+++ b/components/kube/contents/ui/Kube.qml
@@ -89,15 +89,6 @@ Controls2.ApplicationWindow {
89 //END ActionHandler 89 //END ActionHandler
90 90
91 //Controller 91 //Controller
92 Kube.MailController {
93 id: mailController
94 Binding on threadLeader {
95 //!! checks for the availability of the type
96 when: !!mailListView.currentMail
97 value: mailListView.currentMail
98 }
99 }
100
101 Kube.FolderController { 92 Kube.FolderController {
102 id: folderController 93 id: folderController
103 Binding on folder { 94 Binding on folder {
@@ -119,19 +110,6 @@ Controls2.ApplicationWindow {
119 onActivated: folderController.synchronizeAction.execute() 110 onActivated: folderController.synchronizeAction.execute()
120 enabled: folderController.synchronizeAction.enabled 111 enabled: folderController.synchronizeAction.enabled
121 } 112 }
122 Shortcut {
123 sequence: StandardKey.Delete
124 onActivated: mailController.moveToTrashAction.execute()
125 enabled: mailController.moveToTrashAction.enabled
126 }
127 Shortcut {
128 sequence: StandardKey.MoveToNextLine
129 onActivated: mailListView.currentIndex++
130 }
131 Shortcut {
132 sequence: StandardKey.MoveToPreviousLine
133 onActivated: mailListView.currentIndex--
134 }
135 //END Shortcuts 113 //END Shortcuts
136 114
137 //BEGIN background 115 //BEGIN background