summaryrefslogtreecommitdiff
path: root/main_gui.c
diff options
context:
space:
mode:
authorDarkvater <darkvater@openttd.org>2006-11-07 13:08:42 +0000
committerDarkvater <darkvater@openttd.org>2006-11-07 13:08:42 +0000
commit293a89dd71c98fd0340ee78f4003ef9c0804ef5a (patch)
tree4d53dac9232895ee3f473a3b3bb6104c99c82d7f /main_gui.c
parent65e051fe93d12d0cc53258e047b6bf86f47c9ce7 (diff)
downloadopenttd-293a89dd71c98fd0340ee78f4003ef9c0804ef5a.tar.xz
(svn r7095) -Codechange: Move MaxZoomIn function to viewport.h and change it to MaxZoomInOut
with a zoom parameter and a pointer to the window which's viewport we want to zoom.
Diffstat (limited to 'main_gui.c')
-rw-r--r--main_gui.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/main_gui.c b/main_gui.c
index 8009f28e8..879618953 100644
--- a/main_gui.c
+++ b/main_gui.c
@@ -888,11 +888,6 @@ bool DoZoomInOutWindow(int how, Window *w)
return true;
}
-static void MaxZoomIn(void)
-{
- while (DoZoomInOutWindow(ZOOM_IN, FindWindowById(WC_MAIN_WINDOW, 0) ) ) {}
-}
-
static void ToolbarZoomInClick(Window *w)
{
if (DoZoomInOutWindow(ZOOM_IN, FindWindowById(WC_MAIN_WINDOW, 0))) {
@@ -2272,7 +2267,7 @@ static void MainWindowWndProc(Window *w, WindowEvent *e)
Point pt = GetTileBelowCursor();
if (pt.x != -1) {
ScrollMainWindowTo(pt.x, pt.y);
- if (e->we.keypress.keycode == 'Z') MaxZoomIn();
+ if (e->we.keypress.keycode == 'Z') MaxZoomInOut(ZOOM_IN, w);
}
break;
}