From 350f0f2cdb66364ca1b6116b77ef249b54f58421 Mon Sep 17 00:00:00 2001 From: peter1138 Date: Wed, 9 Nov 2005 07:25:55 +0000 Subject: (svn r3157) - Feature: Added patch option to link the terraform toolbar to the rail, road, water and airport toolbars. If enabled, the terraform toolbar will open and close with those toolbars. --- rail_gui.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'rail_gui.c') diff --git a/rail_gui.c b/rail_gui.c index 8fbf0e00a..8fee0cfbd 100644 --- a/rail_gui.c +++ b/rail_gui.c @@ -480,6 +480,10 @@ static void BuildRailToolbWndProc(Window *w, WindowEvent *e) DoCommandByTile(tile, 0, 0, DC_AUTO, CMD_BUILD_TUNNEL); VpSetPresizeRange(tile, _build_tunnel_endtile==0?tile:_build_tunnel_endtile); } break; + + case WE_DESTROY: + if (_patches.link_terraform_toolbar) DeleteWindowById(WC_SCEN_LAND_GEN, 0); + break; } } @@ -571,6 +575,7 @@ void ShowBuildRailToolbar(RailType railtype, int button) _remove_button_clicked = false; if (w != NULL && button >= 0) _build_railroad_button_proc[button](w); + if (_patches.link_terraform_toolbar) ShowTerraformToolbar(); } /* TODO: For custom stations, respect their allowed platforms/lengths bitmasks! -- cgit v1.2.3-54-g00ecf