summaryrefslogtreecommitdiff
path: root/src/build_vehicle_gui.cpp
diff options
context:
space:
mode:
authorbjarni <bjarni@openttd.org>2007-01-24 14:32:20 +0000
committerbjarni <bjarni@openttd.org>2007-01-24 14:32:20 +0000
commit058df1b99fcb3a12f322e963612acb7a6b04555a (patch)
tree3a5b9fe40052ed1cff61cb6dbf3a984c0ecf84f0 /src/build_vehicle_gui.cpp
parent7fffe8b3d4cc8c75d6ae40c487d4b23fb22b2946 (diff)
downloadopenttd-058df1b99fcb3a12f322e963612acb7a6b04555a.tar.xz
(svn r8390) -Codechange (r8384): Rewrote ResizeButtons()
Now it only works on first and last widget to resize It now works with offsets correctly (no longer assumes the left is 0) It's no longer needed to have a widget right of the ones you resize Can handle any number of widgets
Diffstat (limited to 'src/build_vehicle_gui.cpp')
-rw-r--r--src/build_vehicle_gui.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/build_vehicle_gui.cpp b/src/build_vehicle_gui.cpp
index 3355199d9..7be31791b 100644
--- a/src/build_vehicle_gui.cpp
+++ b/src/build_vehicle_gui.cpp
@@ -913,7 +913,7 @@ static void NewVehicleWndProc(Window *w, WindowEvent *e)
break;
case WE_RESIZE:
- if (e->we.sizing.diff.x != 0) ResizeButtons(w, BUILD_VEHICLE_WIDGET_BUILD, BUILD_VEHICLE_WIDGET_RESIZE);
+ if (e->we.sizing.diff.x != 0) ResizeButtons(w, BUILD_VEHICLE_WIDGET_BUILD, BUILD_VEHICLE_WIDGET_RENAME);
if (e->we.sizing.diff.y == 0) break;
w->vscroll.cap += e->we.sizing.diff.y / GetVehicleListHeight(bv->vehicle_type);
@@ -975,7 +975,7 @@ void ShowBuildVehicleWindow(TileIndex tile, byte type)
break;
}
SetupWindowStrings(w, type);
- ResizeButtons(w, BUILD_VEHICLE_WIDGET_BUILD, BUILD_VEHICLE_WIDGET_RESIZE);
+ ResizeButtons(w, BUILD_VEHICLE_WIDGET_BUILD, BUILD_VEHICLE_WIDGET_RENAME);
w->resize.width = w->width;
w->resize.height = w->height;