diff options
-rw-r--r-- | framework/qml/ConversationView.qml | 17 | ||||
-rw-r--r-- | framework/qml/MailListView.qml | 5 |
2 files changed, 4 insertions, 18 deletions
diff --git a/framework/qml/ConversationView.qml b/framework/qml/ConversationView.qml index c8ea74ae..f3011f65 100644 --- a/framework/qml/ConversationView.qml +++ b/framework/qml/ConversationView.qml | |||
@@ -116,23 +116,6 @@ FocusScope { | |||
116 | } | 116 | } |
117 | } | 117 | } |
118 | 118 | ||
119 | onCurrentItemChanged: { | ||
120 | if (currentItem) { | ||
121 | markAsReadTimer.restart() | ||
122 | } | ||
123 | } | ||
124 | |||
125 | Timer { | ||
126 | id: markAsReadTimer | ||
127 | interval: 2000 | ||
128 | running: false | ||
129 | repeat: false | ||
130 | onTriggered: { | ||
131 | if (listView.currentItem && !!listView.currentItem.currentData.mail) { | ||
132 | Kube.Fabric.postMessage(Kube.Messages.markAsRead, {"mail": listView.currentItem.currentData.mail}) | ||
133 | } | ||
134 | } | ||
135 | } | ||
136 | } | 119 | } |
137 | } | 120 | } |
138 | } | 121 | } |
diff --git a/framework/qml/MailListView.qml b/framework/qml/MailListView.qml index 96cf30bc..1cdc664f 100644 --- a/framework/qml/MailListView.qml +++ b/framework/qml/MailListView.qml | |||
@@ -33,7 +33,10 @@ FocusScope { | |||
33 | property bool isUnread : false | 33 | property bool isUnread : false |
34 | property variant currentMail: null | 34 | property variant currentMail: null |
35 | 35 | ||
36 | onCurrentMailChanged: Kube.Fabric.postMessage(Kube.Messages.mailSelection, {"mail":currentMail}) | 36 | onCurrentMailChanged: { |
37 | Kube.Fabric.postMessage(Kube.Messages.markAsRead, {"mail": currentMail}) | ||
38 | Kube.Fabric.postMessage(Kube.Messages.mailSelection, {"mail": currentMail}) | ||
39 | } | ||
37 | 40 | ||
38 | Kube.Listener { | 41 | Kube.Listener { |
39 | filter: Kube.Messages.folderSelection | 42 | filter: Kube.Messages.folderSelection |