-rw-r--r-- | Makefile.am | 17 | ||||
-rw-r--r-- | src/controller/actions/pan.c | 23 | ||||
-rw-r--r-- | src/controller/actions/set_ortho.c | 5 | ||||
-rw-r--r-- | src/controller/actions/zoom.c | 8 | ||||
-rw-r--r-- | src/controller/callbacks/keyboard.c | 2 | ||||
-rw-r--r-- | src/controller/callbacks/mouse.c | 30 | ||||
-rw-r--r-- | src/controller/callbacks/mouse_motion.c | 2 | ||||
-rw-r--r-- | src/controller/callbacks/mouse_wheel.c | 8 | ||||
-rw-r--r-- | src/controller/callbacks/reshape.c | 26 | ||||
-rw-r--r-- | src/model/geometry/map_geometry.c | 10 | ||||
-rw-r--r-- | src/model/state/pan_info_init.h | 2 | ||||
-rw-r--r-- | src/model/state/zoom_info_init.c | 2 |
12 files changed, 70 insertions, 65 deletions
diff --git a/src/controller/callbacks/mouse_wheel.c b/src/controller/callbacks/mouse_wheel.c index 9ca73bc..05ce734 100644 --- a/src/controller/callbacks/mouse_wheel.c +++ b/src/controller/callbacks/mouse_wheel.c | |||
@@ -6,7 +6,7 @@ | |||
6 | 6 | ||
7 | #define S state0 | 7 | #define S state0 |
8 | 8 | ||
9 | void | 9 | void |
10 | mouse_wheel (int button, int dir, int x, int y) | 10 | mouse_wheel (int button, int dir, int x, int y) |
11 | { | 11 | { |
12 | /* | 12 | /* |
@@ -14,8 +14,8 @@ mouse_wheel (int button, int dir, int x, int y) | |||
14 | * start at the position of the mouse. Calculate a bounding box | 14 | * start at the position of the mouse. Calculate a bounding box |
15 | * that will be the selection and zoom to it. | 15 | * that will be the selection and zoom to it. |
16 | */ | 16 | */ |
17 | double width = fabs(S.ortho.max_x - S.ortho.min_x); | 17 | double width = fabs (S.ortho.max_x - S.ortho.min_x); |
18 | double height = fabs(S.ortho.max_y - S.ortho.min_y); | 18 | double height = fabs (S.ortho.max_y - S.ortho.min_y); |
19 | 19 | ||
20 | /* | 20 | /* |
21 | * Box the smaller of the two dimensions. | 21 | * Box the smaller of the two dimensions. |
@@ -60,7 +60,7 @@ mouse_wheel (int button, int dir, int x, int y) | |||
60 | } | 60 | } |
61 | 61 | ||
62 | // Zoom in | 62 | // Zoom in |
63 | if (dir > 0) | 63 | if (dir > 0) |
64 | { | 64 | { |
65 | zoom (x1 + step, y1 + step, x2 - step, y2 - step); | 65 | zoom (x1 + step, y1 + step, x2 - step, y2 - step); |
66 | } | 66 | } |