diff options
author | rubidium <rubidium@openttd.org> | 2008-05-04 09:39:16 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2008-05-04 09:39:16 +0000 |
commit | 8ca10353163dfb34174b4c2a1fad94c3286bb868 (patch) | |
tree | cf16c5b3b35ed64652f1699c981d1887983cc39c /src/road_gui.cpp | |
parent | a26b25aecc9f05727f990ee0c20acb1feef21c9b (diff) | |
download | openttd-8ca10353163dfb34174b4c2a1fad94c3286bb868.tar.xz |
(svn r12939) -Codechange: do not use the window proc to determine whether a toolbar is a rail toolbar, but use the window number.
Diffstat (limited to 'src/road_gui.cpp')
-rw-r--r-- | src/road_gui.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/road_gui.cpp b/src/road_gui.cpp index 2f184d7a9..8872f8530 100644 --- a/src/road_gui.cpp +++ b/src/road_gui.cpp @@ -682,8 +682,8 @@ void ShowBuildRoadToolbar(RoadType roadtype) if (!IsValidPlayer(_current_player)) return; _cur_roadtype = roadtype; - DeleteWindowById(WC_BUILD_TOOLBAR, 0); - Window *w = AllocateWindowDesc(roadtype == ROADTYPE_ROAD ? &_build_road_desc : &_build_tramway_desc); + DeleteWindowByClass(WC_BUILD_TOOLBAR); + Window *w = AllocateWindowDescFront(roadtype == ROADTYPE_ROAD ? &_build_road_desc : &_build_tramway_desc, TRANSPORT_ROAD); if (_patches.link_terraform_toolbar) ShowTerraformToolbar(w); } |