]> Shamusworld >> Repos - architektonas/blob - src/actions/actionsnapintersectionmanual.h
Bugfixes related to removing Snapper class.
[architektonas] / src / actions / actionsnapintersectionmanual.h
1 #ifndef __ACTIONSNAPINTERSECTIONMANUAL_H__
2 #define __ACTIONSNAPINTERSECTIONMANUAL_H__
3
4 #include "actioninterface.h"
5 #include "vector.h"
6
7 class Entity;
8
9 /**
10  * This action class can handle user events to trim entities.
11  *
12  * @author James Hammons
13  * @author Andrew Mustun
14  */
15 class ActionSnapIntersectionManual: public ActionInterface
16 {
17         public:
18                 /**
19                  * Action States.
20                  */
21                 enum Status {
22                         ChooseEntity1, /**< Choosing the 1st entity. */
23                         ChooseEntity2 /**< Choosing the 2nd entity. */
24                 };
25
26         public:
27                 ActionSnapIntersectionManual(EntityContainer & container, GraphicView & graphicView);
28                 ~ActionSnapIntersectionManual();
29
30                 virtual void init(int status = 0);
31                 virtual void trigger();
32                 virtual void mouseMoveEvent(QMouseEvent * e);
33                 virtual void mouseReleaseEvent(QMouseEvent * e);
34                 virtual void updateMouseButtonHints();
35                 virtual void updateMouseCursor();
36                 virtual void updateToolBar();
37
38         private:
39                 Entity * entity1;
40                 Entity * entity2;
41                 Vector coord;
42 };
43
44 #endif  // __ACTIONSNAPINTERSECTIONMANUAL_H__