From 552c4622ae103068ba298d38243f1ca3b9fe6c45 Mon Sep 17 00:00:00 2001 From: Luca Beltrame Date: Wed, 19 Aug 2020 16:34:59 +0200 Subject: [PATCH] Use override directly --- src/model/danboorupostmodel.cpp | 4 ++-- src/model/danboorupostmodel.h | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/model/danboorupostmodel.cpp b/src/model/danboorupostmodel.cpp index 6588c39..4a63111 100644 --- a/src/model/danboorupostmodel.cpp +++ b/src/model/danboorupostmodel.cpp @@ -104,7 +104,7 @@ QVariant DanbooruPostModel::data(const QModelIndex &index, int role) const case RatingRole: return post->rating(); case TagRole: { - QStringList tagList = post->tags().toList(); + QStringList tagList = post->tags().values(); return tagList; } case SampleUrlRole: @@ -146,7 +146,7 @@ QHash< int, QByteArray > DanbooruPostModel::roleNames() const QStringList DanbooruPostModel::postTags() const { - return m_postTags.toList(); + return m_postTags.values(); } diff --git a/src/model/danboorupostmodel.h b/src/model/danboorupostmodel.h index d82f56c..55ff395 100644 --- a/src/model/danboorupostmodel.h +++ b/src/model/danboorupostmodel.h @@ -54,10 +54,10 @@ public: DanbooruPostModel(QObject *parent = 0); ~DanbooruPostModel(); - Q_INVOKABLE int rowCount(const QModelIndex &parent = QModelIndex()) const Q_DECL_OVERRIDE; - QVariant data(const QModelIndex &index, int role) const Q_DECL_OVERRIDE; + Q_INVOKABLE int rowCount(const QModelIndex &parent = QModelIndex()) const override; + QVariant data(const QModelIndex &index, int role) const override; void clear(); - QHash roleNames() const Q_DECL_OVERRIDE; + QHash roleNames() const override; QStringList postTags() const; enum PostRoles {