Rebuild autotool system
[construo.git] / worldview_zoom_tool.hxx
blob2a238a2e1922391d35069ea8f96faf480ae11c7f
1 // $Id: worldview_zoom_tool.hxx,v 1.5 2003/07/24 10:10:02 grumbel Exp $
2 //
3 // Construo - A wire-frame construction gamee
4 // Copyright (C) 2002 Ingo Ruhnke <grumbel@gmx.de>
5 //
6 // This program is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU General Public License
8 // as published by the Free Software Foundation; either version 2
9 // of the License, or (at your option) any later version.
11 // This program is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 // GNU General Public License for more details.
15 //
16 // You should have received a copy of the GNU General Public License
17 // along with this program; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
20 #ifndef HEADER_WORLDVIEW_ZOOM_TOOL_HXX
21 #define HEADER_WORLDVIEW_ZOOM_TOOL_HXX
23 #include "vector2d.hxx"
24 #include "worldview_tool.hxx"
26 /** */
27 class WorldViewZoomTool : public WorldViewTool
29 private:
30 /** Position of the mouse click, click_pos and the button_release
31 pos form the rectangle. click_pos is in world coordinates */
32 Vector2d click_pos;
34 /** true if we are currently creating the zoom rectangle and
35 click_pos is set, false otherwise */
36 bool creating_zoom_rectangle;
37 public:
38 WorldViewZoomTool ();
39 ~WorldViewZoomTool ();
41 void activate ();
43 void draw_foreground (ZoomGraphicContext* gc);
44 void draw_background (ZoomGraphicContext* gc) {}
46 void on_primary_button_press (int x, int y);
47 void on_primary_button_release (int x, int y);
49 void on_secondary_button_press (int x, int y);
50 void on_secondary_button_release (int x, int y);
53 #endif
55 /* EOF */