Fix re-opening GRF/script settings windows not closing drop down windows

Causing assertion failure on drop down item selection

See: #527
This commit is contained in:
Jonathan G Rennison
2023-06-01 21:08:12 +01:00
parent e3bd8966fc
commit 58c0aac15f
3 changed files with 11 additions and 0 deletions

View File

@@ -183,6 +183,11 @@ struct NewGRFParametersWindow : public Window {
this->InvalidateData();
}
~NewGRFParametersWindow()
{
HideDropDownMenu(this);
}
/**
* Get a dummy parameter-info object with default information.
* @param nr The param number that should be changed.