summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorskidd13 <skidd13@openttd.org>2007-12-07 17:51:27 +0000
committerskidd13 <skidd13@openttd.org>2007-12-07 17:51:27 +0000
commit98bd772119d0b603a53b31a875b5a2bc7e9108f7 (patch)
tree08608ddbd8ea54bb37f069f8d8a107276789d08b /src
parent10e17c30a38535e571e28d2a56046c76bda39a97 (diff)
downloadopenttd-98bd772119d0b603a53b31a875b5a2bc7e9108f7.tar.xz
(svn r11587) -Fix (r11457): The one way road button wasn't reset on abort
Diffstat (limited to 'src')
-rw-r--r--src/road_gui.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/road_gui.cpp b/src/road_gui.cpp
index 5e9abf4de..c7b984c61 100644
--- a/src/road_gui.cpp
+++ b/src/road_gui.cpp
@@ -467,9 +467,13 @@ static void BuildRoadToolbWndProc(Window *w, WindowEvent *e)
break;
case WE_ABORT_PLACE_OBJ:
- RaiseWindowButtons(w);
- w->DisableWidget(RTW_REMOVE);
- InvalidateWidget(w, RTW_REMOVE);
+ w->RaiseButtons();
+ w->SetWidgetsDisabledState(true,
+ RTW_REMOVE,
+ RTW_ONE_WAY,
+ WIDGET_LIST_END);
+ w->InvalidateWidget(RTW_REMOVE);
+ w->InvalidateWidget(RTW_ONE_WAY);
w = FindWindowById(WC_BUS_STATION, 0);
if (w != NULL) WP(w, def_d).close = true;