20 #ifndef PRIVMSGSEARCHMODEL_H
21 #define PRIVMSGSEARCHMODEL_H
23 #include <QAbstractListModel>
24 #include "../util/hash.h"
25 #include "../mcontroller.h"
65 virtual int rowCount(
const QModelIndex & parent = QModelIndex())
const ;
70 virtual int columnCount(
const QModelIndex & parent = QModelIndex())
const ;
75 virtual QVariant
data(
const QModelIndex & index,
int role = Qt::DisplayRole)
const ;
76 virtual QVariant
headerData (
int section, Qt::Orientation orientation,
int role = Qt::DisplayRole )
const ;
92 const QString& aExplanation) ;
Hash iMessageHash
Definition: privmsgsearchmodel.h:40
Carrier-class for private msg inside classified ads.
Definition: privmsg.h:35
virtual int columnCount(const QModelIndex &parent=QModelIndex()) const
MController & iController
Definition: privmsgsearchmodel.h:106
QIcon iLeftIcon
Definition: privmsgsearchmodel.h:109
QIcon iRightIcon
Definition: privmsgsearchmodel.h:110
void setAsRead(const Hash &aMessage, bool aIsRead)
Definition: privmsgsearchmodel.h:38
Model & iModel
Definition: privmsgsearchmodel.h:105
~PrivateMessageSearchModel()
QString iSenderName
Definition: privmsgsearchmodel.h:45
Hash is class that carries 160-bit digest.
Definition: hash.h:37
CAErrorSituation
Definition: mcontroller.h:48
void error(MController::CAErrorSituation aError, const QString &aExplanation)
void doUpdateDataOnIdle()
void setSearchHash(const Hash &aSearch)
void newMsgReceived(const Hash &aMessage, const Hash &aRecipient)
quint32 iMessageTimeStamp
Definition: privmsgsearchmodel.h:43
Pure-virtual interface class for controller. This is spammed across parties needing access to applica...
Definition: mcontroller.h:39
Model-class for performing search on private messages. This is supposed to act as an underlying data-...
Definition: privmsgsearchmodel.h:35
Hash iSearchHash
Definition: privmsgsearchmodel.h:108
virtual QVariant data(const QModelIndex &index, int role=Qt::DisplayRole) const
QList< PrivateMessageListItem > iPrivateMessages
Definition: privmsgsearchmodel.h:107
virtual QVariant headerData(int section, Qt::Orientation orientation, int role=Qt::DisplayRole) const
M of the MVC pattern. Handles permanent storage.
Definition: model.h:47
QString iMessageSubject
Definition: privmsgsearchmodel.h:44
PrivateMessageSearchModel(Model &aModel, MController &aController)
Hash iRecipientHash
Definition: privmsgsearchmodel.h:41
void updateSenderAndSubjectOfMsg(PrivateMessageListItem &aItem)
Hash iSenderHash
Definition: privmsgsearchmodel.h:42
bool iIsRead
Definition: privmsgsearchmodel.h:46
virtual int rowCount(const QModelIndex &parent=QModelIndex()) const