From 44565ed793297ff9911c993e2046a559b9d40400 Mon Sep 17 00:00:00 2001 From: Kai Uwe Broulik Date: Tue, 6 Feb 2024 13:16:19 +0100 Subject: [PATCH] Mark QGuiApplication::platformName property as CONSTANT It cannot change at run-time once the platform has been initialized. Change-Id: Ib5ec049d799cbc54f184ebc8a6531f22c02b6b5b Reviewed-by: Fabian Kosmale (cherry picked from commit c587eeef11a00866347e44ec4e701c7775558a07) Reviewed-by: Qt Cherry-pick Bot --- src/gui/kernel/qguiapplication.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/kernel/qguiapplication.h b/src/gui/kernel/qguiapplication.h index 14bce88c62d..23d7fb3d652 100644 --- a/src/gui/kernel/qguiapplication.h +++ b/src/gui/kernel/qguiapplication.h @@ -42,7 +42,7 @@ class Q_GUI_EXPORT QGuiApplication : public QCoreApplication Q_PROPERTY(QString desktopFileName READ desktopFileName WRITE setDesktopFileName) Q_PROPERTY(Qt::LayoutDirection layoutDirection READ layoutDirection WRITE setLayoutDirection NOTIFY layoutDirectionChanged) - Q_PROPERTY(QString platformName READ platformName STORED false) + Q_PROPERTY(QString platformName READ platformName STORED false CONSTANT) Q_PROPERTY(bool quitOnLastWindowClosed READ quitOnLastWindowClosed WRITE setQuitOnLastWindowClosed) Q_PROPERTY(QScreen *primaryScreen READ primaryScreen NOTIFY primaryScreenChanged STORED false)