From 433202a881d39272c9928a90365f05811520cbed Mon Sep 17 00:00:00 2001 From: wmayer Date: Tue, 13 Dec 2016 14:53:43 +0100 Subject: [PATCH] drop inheritance of PropertyItem from BaseClass --- src/Gui/propertyeditor/PropertyItem.h | 6 +++--- src/Mod/Sketcher/Gui/PropertyConstraintListItem.cpp | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Gui/propertyeditor/PropertyItem.h b/src/Gui/propertyeditor/PropertyItem.h index 2c609bdcc..ac9c821fa 100644 --- a/src/Gui/propertyeditor/PropertyItem.h +++ b/src/Gui/propertyeditor/PropertyItem.h @@ -101,7 +101,7 @@ public: } }; -class GuiExport PropertyItem : virtual public QObject, public Base::BaseClass, public ExpressionBinding +class GuiExport PropertyItem : public QObject, public ExpressionBinding { Q_OBJECT PROPERTYITEM_HEADER @@ -128,8 +128,8 @@ public: childs which like to be informed of a binding*/ virtual void bind(const App::Property& prop); virtual void bind(const App::ObjectIdentifier& _path); - virtual void propertyBound() {}; - + virtual void propertyBound() {} + void setParent(PropertyItem* parent); PropertyItem *parent() const; void appendChild(PropertyItem *child); diff --git a/src/Mod/Sketcher/Gui/PropertyConstraintListItem.cpp b/src/Mod/Sketcher/Gui/PropertyConstraintListItem.cpp index ad1ddbae2..63bb8b750 100644 --- a/src/Mod/Sketcher/Gui/PropertyConstraintListItem.cpp +++ b/src/Mod/Sketcher/Gui/PropertyConstraintListItem.cpp @@ -211,7 +211,7 @@ bool PropertyConstraintListItem::event (QEvent* ev) Sketcher::PropertyConstraintList* item; int id = 0; - if (this->parent()->getTypeId() == SketcherGui::PropertyConstraintListItem::getClassTypeId()) { + if (dynamic_cast(this->parent())) { item = static_cast(this->parent()->getFirstProperty()); } else {