diff options
author | Trial97 <alexandru.tripon97@gmail.com> | 2023-09-28 22:50:12 +0300 |
---|---|---|
committer | Trial97 <alexandru.tripon97@gmail.com> | 2023-09-28 22:50:12 +0300 |
commit | 9acbf98f940204cd141203a6eccbc9a7351e5a78 (patch) | |
tree | 6ac8fe4b0e51ee58c67e02783fe97b00de707167 /launcher/VersionProxyModel.cpp | |
parent | 254444470f020b086648ac496ebfffb7d3e9ce05 (diff) | |
parent | 59e565ef96b85be9a25fa5d4f1723ee87fd5e75e (diff) | |
download | PrismLauncher-9acbf98f940204cd141203a6eccbc9a7351e5a78.tar.gz PrismLauncher-9acbf98f940204cd141203a6eccbc9a7351e5a78.tar.bz2 PrismLauncher-9acbf98f940204cd141203a6eccbc9a7351e5a78.zip |
Merge branch 'develop' of https://github.com/PrismLauncher/PrismLauncher into feat/acknowledge_release_type
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
Diffstat (limited to 'launcher/VersionProxyModel.cpp')
-rw-r--r-- | launcher/VersionProxyModel.cpp | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/launcher/VersionProxyModel.cpp b/launcher/VersionProxyModel.cpp index 6e0333e4..0ab9ae2c 100644 --- a/launcher/VersionProxyModel.cpp +++ b/launcher/VersionProxyModel.cpp @@ -194,12 +194,12 @@ QVariant VersionProxyModel::data(const QModelIndex& index, int role) const switch (column) { case Name: { if (hasRecommended) { - auto value = sourceModel()->data(parentIndex, BaseVersionList::RecommendedRole); - if (value.toBool()) { + auto recommenced = sourceModel()->data(parentIndex, BaseVersionList::RecommendedRole); + if (recommenced.toBool()) { return APPLICATION->getThemedIcon("star"); } else if (hasLatest) { - auto value = sourceModel()->data(parentIndex, BaseVersionList::LatestRole); - if (value.toBool()) { + auto latest = sourceModel()->data(parentIndex, BaseVersionList::LatestRole); + if (latest.toBool()) { return APPLICATION->getThemedIcon("bug"); } } @@ -228,7 +228,7 @@ QVariant VersionProxyModel::data(const QModelIndex& index, int role) const } } -QModelIndex VersionProxyModel::parent(const QModelIndex& child) const +QModelIndex VersionProxyModel::parent([[maybe_unused]] const QModelIndex& child) const { return QModelIndex(); } @@ -408,7 +408,9 @@ void VersionProxyModel::sourceRowsAboutToBeInserted(const QModelIndex& parent, i beginInsertRows(parent, first, last); } -void VersionProxyModel::sourceRowsInserted(const QModelIndex& parent, int first, int last) +void VersionProxyModel::sourceRowsInserted([[maybe_unused]] const QModelIndex& parent, + [[maybe_unused]] int first, + [[maybe_unused]] int last) { endInsertRows(); } @@ -418,7 +420,7 @@ void VersionProxyModel::sourceRowsAboutToBeRemoved(const QModelIndex& parent, in beginRemoveRows(parent, first, last); } -void VersionProxyModel::sourceRowsRemoved(const QModelIndex& parent, int first, int last) +void VersionProxyModel::sourceRowsRemoved([[maybe_unused]] const QModelIndex& parent, [[maybe_unused]] int first, [[maybe_unused]] int last) { endRemoveRows(); } |