Returns the activity type to the list view.

Signed-off-by: Camila San <hello@camila.codes>
This commit is contained in:
Camila San 2018-04-17 19:01:21 +02:00 committed by Roeland Jago Douma
parent 2350b41dc3
commit 4e4a0da3b7
No known key found for this signature in database
GPG Key ID: F941078878347C0C
3 changed files with 8 additions and 0 deletions

View File

@ -85,6 +85,7 @@ bool operator<(const Activity &rhs, const Activity &lhs);
typedef QList<Activity> ActivityList;
}
Q_DECLARE_METATYPE(OCC::Activity::Type)
Q_DECLARE_METATYPE(OCC::ActivityLink)
#endif // ACTIVITYDATA_H

View File

@ -31,6 +31,7 @@ public:
AccountRole,
ActionsLinksRole,
ActionTextRole,
ActionRole,
MessageRole,
PathRole,
LinkRole,

View File

@ -87,6 +87,12 @@ QVariant ActivityListModel::data(const QModelIndex &index, int role) const
return QIcon(QLatin1String(":/client/resources/activity.png"));
return QVariant();
break;
case ActivityItemDelegate::ActionRole:{
QVariant type;
type.setValue(a._type);
return type;
break;
}
case Qt::ToolTipRole:
case ActivityItemDelegate::ActionTextRole:
return a._subject;