glc_mover.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00026
00027 #ifndef GLC_MOVER_H_
00028 #define GLC_MOVER_H_
00029
00030 #include "glc_repmover.h"
00031 #include "../maths/glc_vector3d.h"
00032
00033 #include <QObject>
00034 #include <QList>
00035
00036 #include "../glc_config.h"
00037
00038 class QMouseEvent;
00039 class GLC_Viewport;
00040
00043
00044
00045 class GLC_LIB_EXPORT GLC_Mover : public QObject
00046 {
00047 Q_OBJECT
00048
00049 public:
00051 GLC_Mover(GLC_Viewport*, const QList<GLC_RepMover*>&);
00052
00054 GLC_Mover(const GLC_Mover&);
00055
00057 virtual ~GLC_Mover();
00058
00059
00061
00063
00064 public:
00066 virtual GLC_Mover* clone() const= 0;
00068
00070
00072
00073 public:
00075 virtual void init(QMouseEvent * e)= 0;
00076
00078 virtual bool move(QMouseEvent * e)= 0;
00079
00081 virtual void ends(){}
00082
00084 void setRepresentationsList(const QList<GLC_RepMover*>&);
00085
00087 void initRepresentation();
00088
00090 void updateRepresentation();
00091
00092
00094
00096
00098
00099 public:
00101 void glExecute();
00102
00104
00105 signals:
00107 void updated();
00108
00110
00112 private:
00114 void clearMoverRepresentation();
00115
00117
00119 private:
00121 QList<GLC_RepMover*> m_RepMoverList;
00122
00124
00126 protected:
00127
00129 GLC_Vector3d m_PreviousVector;
00130
00132 GLC_Viewport* m_pViewport;
00133
00135 GLC_RepMover::RepMoverInfo m_MoverInfo;
00136 };
00137
00138 #endif