summaryrefslogtreecommitdiffstats
path: root/framework/domain/maillistmodel.cpp
diff options
context:
space:
mode:
authorChristian Mollekopf <chrigi_1@fastmail.fm>2017-03-23 10:39:58 +0100
committerChristian Mollekopf <chrigi_1@fastmail.fm>2017-03-23 10:39:58 +0100
commitc920d2346b39da89297aede673e9853829e181b3 (patch)
treec370450a6c7cf33bd534ea52646389be13345b76 /framework/domain/maillistmodel.cpp
parent7d968fb8e51977ce7b49e0b8ccf96d8e30868426 (diff)
downloadkube-c920d2346b39da89297aede673e9853829e181b3.tar.gz
kube-c920d2346b39da89297aede673e9853829e181b3.zip
Show something if the data is not yet available.
We're still missing: * For empty folders we have to differentiate between truly empty folder, and folders that have not been synchronized yet. Further an indicator when the fetch is in progress would be useful. * For mails we need to indicate when the mail is being fetched.
Diffstat (limited to 'framework/domain/maillistmodel.cpp')
-rw-r--r--framework/domain/maillistmodel.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/framework/domain/maillistmodel.cpp b/framework/domain/maillistmodel.cpp
index 5a462021..bdf7b9f5 100644
--- a/framework/domain/maillistmodel.cpp
+++ b/framework/domain/maillistmodel.cpp
@@ -66,6 +66,7 @@ QHash< int, QByteArray > MailListModel::roleNames() const
66 roles[DomainObject] = "domainObject"; 66 roles[DomainObject] = "domainObject";
67 roles[ThreadSize] = "threadSize"; 67 roles[ThreadSize] = "threadSize";
68 roles[Mail] = "mail"; 68 roles[Mail] = "mail";
69 roles[Incomplete] = "incomplete";
69 70
70 return roles; 71 return roles;
71} 72}
@@ -134,6 +135,8 @@ QVariant MailListModel::data(const QModelIndex &idx, int role) const
134 return mail->getProperty("count").toInt(); 135 return mail->getProperty("count").toInt();
135 case Mail: 136 case Mail:
136 return QVariant::fromValue(mail); 137 return QVariant::fromValue(mail);
138 case Incomplete:
139 return !mail->getFullPayloadAvailable();
137 } 140 }
138 return QSortFilterProxyModel::data(idx, role); 141 return QSortFilterProxyModel::data(idx, role);
139} 142}