diff options
author | smatz <smatz@openttd.org> | 2007-12-17 22:04:07 +0000 |
---|---|---|
committer | smatz <smatz@openttd.org> | 2007-12-17 22:04:07 +0000 |
commit | bda9d4a23633c4ebb6ad18c29218deaf1a92d55d (patch) | |
tree | e1686070db2bce48c4953e4bbef6a196640ae495 /src/main_gui.cpp | |
parent | 61dcdbf0e0bbbe231b7adbd0a82da8d9e16dbb88 (diff) | |
download | openttd-bda9d4a23633c4ebb6ad18c29218deaf1a92d55d.tar.xz |
(svn r11656) -Codechange: add ZOOM_LVL_BEGIN and postfix operators so ZoomLevel can be used in some iterations
Diffstat (limited to 'src/main_gui.cpp')
-rw-r--r-- | src/main_gui.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main_gui.cpp b/src/main_gui.cpp index d85ec6369..66d854060 100644 --- a/src/main_gui.cpp +++ b/src/main_gui.cpp @@ -872,7 +872,7 @@ bool DoZoomInOutWindow(int how, Window *w) switch (how) { case ZOOM_IN: if (vp->zoom == ZOOM_LVL_MIN) return false; - vp->zoom = (ZoomLevel)((byte)vp->zoom - 1); + vp->zoom = (ZoomLevel)((int)vp->zoom - 1); vp->virtual_width >>= 1; vp->virtual_height >>= 1; @@ -883,7 +883,7 @@ bool DoZoomInOutWindow(int how, Window *w) break; case ZOOM_OUT: if (vp->zoom == ZOOM_LVL_MAX) return false; - vp->zoom = (ZoomLevel)((byte)vp->zoom + 1); + vp->zoom = (ZoomLevel)((int)vp->zoom + 1); WP(w, vp_d).scrollpos_x -= vp->virtual_width >> 1; WP(w, vp_d).scrollpos_y -= vp->virtual_height >> 1; |