00001 #ifndef PSQT_DRAGCENTER_H
00002 #define PSQT_DRAGCENTER_H
00003
00004
00005 #include "PSQt/DragBase.h"
00006
00007
00008 #include <iostream>
00009 #include <fstream>
00010 #include <sstream>
00011
00012 namespace PSQt {
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051 class DragCenter : public DragBase
00052 {
00053 Q_OBJECT
00054
00055 public:
00056
00057
00058
00059
00060
00061
00062
00063 DragCenter(WdgImage* wimg=0, const QPointF* points=0);
00064 virtual ~DragCenter(){};
00065
00066 virtual void draw(const DRAGMODE& mode=DRAW);
00067 virtual bool contains(const QPointF& p);
00068 virtual void move(const QPointF& p);
00069 virtual void moveIsCompleted(const QPointF& p);
00070 virtual void create();
00071
00072 virtual void print();
00073
00074 virtual const QPointF& getCenter(){ return m_points_raw[0]; };
00075
00076
00077 void forceToEmitSignal();
00078
00079 signals:
00080 void centerIsMoved(const QPointF&);
00081 void centerIsChanged(const QPointF&);
00082
00083 public slots:
00084 void moveToRaw(const QPointF&);
00085 void testSignalCenterIsChanged(const QPointF&);
00086 void testSignalCenterIsMoved(const QPointF&);
00087
00088 protected:
00089
00090 private:
00091 virtual const char* _name_(){return "DragCenter";}
00092
00093 };
00094
00095
00096
00097 }
00098
00099 #endif // PSQT_DRAGCENTER_H
00100
00101
00102
00103