diff --git a/src/app/tools/drawTools/vtoolheight.cpp b/src/app/tools/drawTools/vtoolheight.cpp index 067cab00c..a77417454 100644 --- a/src/app/tools/drawTools/vtoolheight.cpp +++ b/src/app/tools/drawTools/vtoolheight.cpp @@ -257,3 +257,40 @@ void VToolHeight::SaveOptions(QDomElement &tag, QSharedPointer &obj) doc->SetAttribute(tag, AttrP1Line, p1LineId); doc->SetAttribute(tag, AttrP2Line, p2LineId); } + +//--------------------------------------------------------------------------------------------------------------------- +quint32 VToolHeight::getP2LineId() const +{ + return p2LineId; +} + +//--------------------------------------------------------------------------------------------------------------------- +void VToolHeight::setP2LineId(const quint32 &value) +{ + if (value != NULL_ID) + { + p2LineId = value; + + QSharedPointer obj = VAbstractTool::data.GetGObject(id); + SaveOption(obj); + } +} + +//--------------------------------------------------------------------------------------------------------------------- +quint32 VToolHeight::getP1LineId() const +{ + return p1LineId; +} + +//--------------------------------------------------------------------------------------------------------------------- +void VToolHeight::setP1LineId(const quint32 &value) +{ + if (value != NULL_ID) + { + p1LineId = value; + + QSharedPointer obj = VAbstractTool::data.GetGObject(id); + SaveOption(obj); + } +} + diff --git a/src/app/tools/drawTools/vtoolheight.h b/src/app/tools/drawTools/vtoolheight.h index bbbfabf3a..34e7b6c09 100644 --- a/src/app/tools/drawTools/vtoolheight.h +++ b/src/app/tools/drawTools/vtoolheight.h @@ -52,6 +52,13 @@ public: static const QString ToolType; virtual int type() const {return Type;} enum { Type = UserType + static_cast(Tool::Height)}; + + quint32 getP1LineId() const; + void setP1LineId(const quint32 &value); + + quint32 getP2LineId() const; + void setP2LineId(const quint32 &value); + public slots: virtual void FullUpdateFromFile(); virtual void ShowContextMenu(QGraphicsSceneContextMenuEvent *event);