]> git.tdb.fi Git - r2c2.git/blob - source/designer/extendtool.h
979c9205ef7038ba907ef60498c74000b5700de1
[r2c2.git] / source / designer / extendtool.h
1 #ifndef EXTENDTOOL_H_
2 #define EXTENDTOOL_H_
3
4 #include <set>
5 #include <vector>
6 #include "libr2c2/track.h"
7 #include "tool.h"
8
9 class ExtendTool: public Tool
10 {
11 private:
12         std::set<R2C2::Object *> objects;
13         std::vector<R2C2::Track *> extend_tracks;
14         bool accepted;
15
16 public:
17         ExtendTool(Designer &, Msp::Input::Mouse &, const std::set<R2C2::Object *> &);
18         virtual ~ExtendTool();
19
20         void connect();
21
22         virtual void button_press(unsigned);
23         virtual void axis_motion(unsigned, float, float);
24
25 private:
26         std::vector<R2C2::Track *> create_straight(const R2C2::Vector &, const R2C2::Angle &, float, float);
27
28 public:
29         virtual void update_selection(Selection &) const;
30 };
31
32 #endif