summaryrefslogtreecommitdiff
path: root/src/settings_gui.cpp
diff options
context:
space:
mode:
authorglx22 <glx@openttd.org>2021-05-15 23:12:25 +0200
committerLoïc Guilloux <glx22@users.noreply.github.com>2021-05-29 21:08:25 +0200
commit994bf19aef3dde6c9482434bdc51688f76a937ea (patch)
tree9b45b82d460cb00733144ba0dd64ebc6fde478c2 /src/settings_gui.cpp
parentef991b1772f5f8b4874f76ea715a9a95811ad979 (diff)
downloadopenttd-994bf19aef3dde6c9482434bdc51688f76a937ea.tar.xz
Fix f6d5c01: Delay deletion when closing windows
Diffstat (limited to 'src/settings_gui.cpp')
-rw-r--r--src/settings_gui.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/settings_gui.cpp b/src/settings_gui.cpp
index 559c39587..6fae298bc 100644
--- a/src/settings_gui.cpp
+++ b/src/settings_gui.cpp
@@ -172,11 +172,12 @@ struct GameOptionsWindow : Window {
this->OnInvalidateData(0);
}
- ~GameOptionsWindow()
+ void Close() override
{
DeleteWindowById(WC_CUSTOM_CURRENCY, 0);
DeleteWindowByClass(WC_TEXTFILE);
if (this->reload) _switch_mode = SM_MENU;
+ this->Window::Close();
}
/**