diff options
author | Javier S. Pedro <maemo@javispedro.com> | 2013-05-01 02:42:50 +0200 |
---|---|---|
committer | Javier S. Pedro <maemo@javispedro.com> | 2013-05-01 02:42:50 +0200 |
commit | 5c3ba8460a9784acb784337a2c11b5175fd7c011 (patch) | |
tree | 119f4c0010bba0383adced817ef921a986754bf8 /topicmodel.cpp | |
parent | c6f60740cc4ca2db17b415e77008cbc5c347f9d7 (diff) | |
download | tapasboard-5c3ba8460a9784acb784337a2c11b5175fd7c011.tar.gz tapasboard-5c3ba8460a9784acb784337a2c11b5175fd7c011.zip |
rewrite date/time formatting
Diffstat (limited to 'topicmodel.cpp')
-rw-r--r-- | topicmodel.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/topicmodel.cpp b/topicmodel.cpp index 36fc4c0..abfd04b 100644 --- a/topicmodel.cpp +++ b/topicmodel.cpp @@ -132,9 +132,12 @@ QVariant TopicModel::data(const QModelIndex &index, int role) const case DateTimeRole: return _data[row].time; case HumanDateRole: - return _board->renderHumanDate(_data[row].time); + return _board->formatDateTime(_data[row].time, + Board::RelativeDate); case HumanTimeRole: - return _board->renderHumanDateTime(_data[row].time); + return _board->formatDateTime(_data[row].time, + Board::ShowTime | Board::RelativeTime | + Board::TodayYesterday); case UnreadRole: return _firstUnread >= 0 && row >= _firstUnread; } |