From 53b95862ad9613577b361aeefe1135676da86b64 Mon Sep 17 00:00:00 2001 From: Henning Gruendl Date: Thu, 7 Nov 2019 14:57:16 +0100 Subject: [PATCH] QmlDesigner: Fix coding style Change-Id: I597f906627ac690cb1e066c394f11ecaeced90d9 Reviewed-by: Thomas Hartmann --- .../components/propertyeditor/aligndistribute.cpp | 2 +- .../qmldesigner/components/propertyeditor/aligndistribute.h | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/plugins/qmldesigner/components/propertyeditor/aligndistribute.cpp b/src/plugins/qmldesigner/components/propertyeditor/aligndistribute.cpp index d6ef557388c..297e815b956 100644 --- a/src/plugins/qmldesigner/components/propertyeditor/aligndistribute.cpp +++ b/src/plugins/qmldesigner/components/propertyeditor/aligndistribute.cpp @@ -109,7 +109,7 @@ void AlignDistribute::setModelNodeBackend(const QVariant &modelNodeBackend) // The purpose of this function is to suppress the following warning: // Warning: Property declaration modelNodeBackendProperty has no READ accessor // function or associated MEMBER variable. The property will be invalid. -QVariant AlignDistribute::getModelNodeBackend() const +QVariant AlignDistribute::modelNodeBackend() const { return {}; } diff --git a/src/plugins/qmldesigner/components/propertyeditor/aligndistribute.h b/src/plugins/qmldesigner/components/propertyeditor/aligndistribute.h index 1b2714f7503..9fbbab4b068 100644 --- a/src/plugins/qmldesigner/components/propertyeditor/aligndistribute.h +++ b/src/plugins/qmldesigner/components/propertyeditor/aligndistribute.h @@ -44,7 +44,7 @@ class AlignDistribute : public QObject Q_PROPERTY(bool selectionContainsRootItem READ selectionContainsRootItem NOTIFY modelNodeBackendChanged) - Q_PROPERTY(QVariant modelNodeBackendProperty READ getModelNodeBackend WRITE setModelNodeBackend + Q_PROPERTY(QVariant modelNodeBackendProperty READ modelNodeBackend WRITE setModelNodeBackend NOTIFY modelNodeBackendChanged) public: @@ -68,7 +68,6 @@ public: bool selectionContainsRootItem() const; void setModelNodeBackend(const QVariant &modelNodeBackend); - QVariant getModelNodeBackend() const; static void registerDeclarativeType(); @@ -83,6 +82,9 @@ public: signals: void modelNodeBackendChanged(); +private: + QVariant modelNodeBackend() const; + private: using CompareFunction = std::function;