From 3bf839f3b97c986b877a0451fa3a94943ea19831 Mon Sep 17 00:00:00 2001 From: Lars Schmertmann Date: Sat, 27 Jun 2020 12:57:31 +0200 Subject: Add ; to Q_UNUSED This is required to remove the ; from the macro with Qt 6. Task-number: QTBUG-82978 Change-Id: I56268bc09fe861effc514acb4033bf8873873ab0 Reviewed-by: Volker Hilsheimer --- src/dialogs/plugin.cpp | 8 ++++---- tests/auto/testplugin/testcppmodels.h | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/dialogs/plugin.cpp b/src/dialogs/plugin.cpp index 9470c208..2f34c87f 100644 --- a/src/dialogs/plugin.cpp +++ b/src/dialogs/plugin.cpp @@ -177,8 +177,8 @@ protected: if (!registerWidgetImplementation( widgetsDir, qmlDir, qmlName, uri, hasTopLevelWindows, versionMajor, versionMinor)) #else - Q_UNUSED(widgetsDir) - Q_UNUSED(hasTopLevelWindows) + Q_UNUSED(widgetsDir); + Q_UNUSED(hasTopLevelWindows); #endif registerQmlImplementation(qmlDir, qmlName, uri, versionMajor, versionMinor); } @@ -187,7 +187,7 @@ protected: bool registerWidgetImplementation(const QDir &widgetsDir, const QDir &qmlDir, const char *qmlName, const char *uri, bool hasTopLevelWindows, int versionMajor, int versionMinor) { - Q_UNUSED(qmlDir) + Q_UNUSED(qmlDir); bool mobileTouchPlatform = false; #if defined(Q_OS_IOS) mobileTouchPlatform = true; @@ -217,7 +217,7 @@ protected: template void registerQmlImplementation(const QDir &qmlDir, const char *qmlName, const char *uri , int versionMajor, int versionMinor) { - Q_UNUSED(qmlDir) + Q_UNUSED(qmlDir); qCDebug(lcRegistration) << "Register QML version for" << qmlName << "with uri:" << uri; QByteArray abstractTypeName = QByteArray("Abstract") + qmlName; diff --git a/tests/auto/testplugin/testcppmodels.h b/tests/auto/testplugin/testcppmodels.h index 03b598c4..44de1ca3 100644 --- a/tests/auto/testplugin/testcppmodels.h +++ b/tests/auto/testplugin/testcppmodels.h @@ -114,13 +114,13 @@ public: virtual bool canFetchMore(const QModelIndex &parent) const { - Q_UNUSED(parent) + Q_UNUSED(parent); return true; } virtual void fetchMore(const QModelIndex & parent) { - Q_UNUSED(parent) + Q_UNUSED(parent); addMoreData(); } -- cgit v1.2.1