1
0
Fork 0

Fix: Rail waypoint selection window not closed

When rail toolbar or rail waypoint build windows closed
pull/10922/head
Jonathan G Rennison 2023-05-25 23:15:15 +01:00 committed by Loïc Guilloux
parent 7969907116
commit a75a90b3af
1 changed files with 7 additions and 0 deletions

View File

@ -423,6 +423,7 @@ struct BuildRailToolbarWindow : Window {
{
if (this->IsWidgetLowered(WID_RAT_BUILD_STATION)) SetViewportCatchmentStation(nullptr, true);
if (_settings_client.gui.link_terraform_toolbar) CloseWindowById(WC_SCEN_LAND_GEN, 0, false);
CloseWindowById(WC_SELECT_STATION, 0);
this->Window::Close();
}
@ -2024,6 +2025,12 @@ struct BuildRailWaypointWindow : PickerWindowBase {
matrix->SetClicked(_cur_waypoint_type);
}
void Close() override
{
CloseWindowById(WC_SELECT_STATION, 0);
this->PickerWindowBase::Close();
}
void UpdateWidgetSize(int widget, Dimension *size, const Dimension &padding, Dimension *fill, Dimension *resize) override
{
switch (widget) {