00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef QGSMAPTOOLZOOM_H
00018 #define QGSMAPTOOLZOOM_H
00019
00020 #include "qgsmaptool.h"
00021 #include <QRect>
00022
00023
00024 class QRubberBand;
00025
00030 class GUI_EXPORT QgsMapToolZoom : public QgsMapTool
00031 {
00032 public:
00034 QgsMapToolZoom( QgsMapCanvas* canvas, bool zoomOut );
00035
00037 virtual void canvasMoveEvent( QMouseEvent * e );
00038
00040 virtual void canvasPressEvent( QMouseEvent * e );
00041
00043 virtual void canvasReleaseEvent( QMouseEvent * e );
00044
00045 virtual bool isTransient() { return true; }
00046
00047 protected:
00049 QRect mZoomRect;
00050
00052 bool mZoomOut;
00053
00055 bool mDragging;
00056
00058 QRubberBand* mRubberBand;
00059 };
00060
00061 #endif