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
00024
00025 #ifndef GLC_MOVER_H_
00026 #define GLC_MOVER_H_
00027
00028 #include "glc_repmover.h"
00029 #include "../maths/glc_vector3d.h"
00030 #include "glc_userinput.h"
00031
00032 #include <QObject>
00033 #include <QList>
00034
00035 #include "../glc_config.h"
00036
00037 class GLC_Viewport;
00038
00041
00042
00043 class GLC_LIB_EXPORT GLC_Mover : public QObject
00044 {
00045 Q_OBJECT
00046
00047 public:
00049 GLC_Mover(GLC_Viewport*, const QList<GLC_RepMover*>&);
00050
00052 GLC_Mover(const GLC_Mover&);
00053
00055 virtual ~GLC_Mover();
00056
00057
00059
00061
00062 public:
00064 virtual GLC_Mover* clone() const= 0;
00066
00068
00070
00071 public:
00073 virtual void init(const GLC_UserInput& userInput)= 0;
00074
00076 virtual bool move(const GLC_UserInput& userInput)= 0;
00077
00079 virtual void ends(){}
00080
00082 void setRepresentationsList(const QList<GLC_RepMover*>&);
00083
00085 void initRepresentation();
00086
00088 void updateRepresentation();
00089
00090
00092
00094
00096
00097 public:
00099 void renderRepresentation();
00100
00102
00103 signals:
00105 void updated();
00106
00108
00110 private:
00112 void clearMoverRepresentation();
00113
00115
00117 protected:
00119 QList<GLC_RepMover*> m_RepMoverList;
00120
00122 GLC_Vector3d m_PreviousVector;
00123
00125 GLC_Viewport* m_pViewport;
00126
00128 GLC_RepMover::RepMoverInfo m_MoverInfo;
00129 };
00130
00131 #endif