diff options
author | Thales Lima Oliveira <thaleslima.ufu@gmail.com> | 2016-08-21 22:14:56 -0300 |
---|---|---|
committer | Thales Lima Oliveira <thaleslima.ufu@gmail.com> | 2016-08-21 22:14:56 -0300 |
commit | 19c800c4f843081420ae6241017e439e7b6da132 (patch) | |
tree | 0afaf838f39270e9f26621d82dd1a6977b228d6c /Project/Element.h | |
parent | 474b1f94ced70e1d183a79bb6df87603982755aa (diff) | |
download | PSP.git-19c800c4f843081420ae6241017e439e7b6da132.tar.gz PSP.git-19c800c4f843081420ae6241017e439e7b6da132.tar.xz PSP.git-19c800c4f843081420ae6241017e439e7b6da132.zip |
Line implementation almost finished
Diffstat (limited to 'Project/Element.h')
-rw-r--r-- | Project/Element.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/Project/Element.h b/Project/Element.h index eb89640..0b2d4be 100644 --- a/Project/Element.h +++ b/Project/Element.h @@ -24,8 +24,8 @@ enum ContextMenuID ID_LINE_ADD_NODE, ID_LINE_REMOVE_NODE, - - ID_ROTATE + + ID_ROTATE }; class Element @@ -68,11 +68,14 @@ class Element virtual void StartMove(wxPoint2DDouble position); virtual void Move(wxPoint2DDouble position); virtual void MoveNode(Element* parent, wxPoint2DDouble position){}; + virtual bool NodeContains(wxPoint2DDouble position) { return false; }; + virtual bool SetNodeParent(Element* parent) { return false; }; virtual void RotateNode(Element* parent) {} virtual wxPoint2DDouble GetSwitchPoint(Element* parent, wxPoint2DDouble parentPoint, wxPoint2DDouble secondPoint) const; virtual void ResetPickboxes() { m_activePickboxID = ID_PB_NONE; } + virtual void ResetNodes() { m_activeNodeID= 0; } virtual wxPoint2DDouble WorldToScreen(wxPoint2DDouble translation, double scale, double offsetX = 0.0, @@ -108,6 +111,7 @@ class Element bool m_showPickbox = false; int m_activePickboxID = ID_PB_NONE; + int m_activeNodeID = 0; wxPoint2DDouble m_moveStartPt; wxPoint2DDouble m_movePos; |