00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #ifndef GLWINDOW_QT_HH
00025 #define GLWINDOW_QT_HH
00026
00027
00028 #include "creation-objet.qt.hh"
00029 #include "dialog-operations.qt.hh"
00030 #include "options-carac.qt.hh"
00031 #include "select-bar.qt.hh"
00032
00033
00034 #include "controler.hh"
00035 #include "controler-gmap.hh"
00036
00037
00038 #include <QtGui/QWorkspace>
00039
00040 class Window ;
00041
00042 class GLWindow : public QGLWidget
00043 {
00044 Q_OBJECT
00045
00046 public:
00047
00055 GLWindow ( TView AViewType , QWorkspace * parent , Window * owner ,
00056 SelectBar * selection ) ;
00057
00066 GLWindow ( TView AViewType , QWorkspace * parent ,
00067 Window * owner , GLWindow * share , SelectBar * selection ) ;
00068
00072 virtual ~GLWindow ( ) ;
00073
00078 virtual TView getViewType ( ) const ;
00079
00084 virtual TViewId getViewId ( ) const ;
00085
00090 virtual string getViewTypeString() const;
00091
00096 virtual void closeEvent ( QCloseEvent * e ) ;
00097
00102 virtual TViewId getCliquedViewId ( ) const ;
00103
00108 virtual TViewId getDoubleCliquedViewId ( ) const ;
00109
00110 protected:
00111
00115 virtual void initializeGL ( ) ;
00116
00120 virtual void paintGL ( ) ;
00121
00125 virtual void creation ( ) ;
00126
00131 virtual void mousePressEvent ( QMouseEvent * e ) ;
00132
00137 virtual void mouseReleaseEvent ( QMouseEvent * e ) ;
00138
00143 virtual void mouseMoveEvent ( QMouseEvent * e ) ;
00144
00150 virtual void resizeGL ( int W , int H ) ;
00151
00156 virtual void mouseDoubleClickEvent ( QMouseEvent * e ) ;
00157
00158
00159 TViewId FViewId;
00160 TView FViewType;
00161
00162
00163 GLWindow * FShared ;
00164
00165
00166 bool isShared;
00167
00168
00169 Window * FOwner ;
00170
00171
00172 SelectBar * FSelection ;
00173
00174
00175 int FStartX, FStartY, FCurX, FCurY;
00176 bool FDragMode;
00177 } ;
00178
00179 #endif