From 999246f63eb1d83a25363e27ea26c1cb640e3c93 Mon Sep 17 00:00:00 2001 From: rubidium Date: Fri, 19 Nov 2010 13:24:32 +0000 Subject: (svn r21255) -Fix (r179): main menu error messages wouldn't show when you had an error message open in the game while whatever triggered you to go back to the main menu --- src/misc_gui.cpp | 2 -- src/openttd.cpp | 1 + 2 files changed, 1 insertion(+), 2 deletions(-) (limited to 'src') diff --git a/src/misc_gui.cpp b/src/misc_gui.cpp index 5db7b91a3..4316adc7d 100644 --- a/src/misc_gui.cpp +++ b/src/misc_gui.cpp @@ -713,8 +713,6 @@ public: ~ErrmsgWindow() { SetRedErrorSquare(INVALID_TILE); - extern StringID _switch_mode_errorstr; - _switch_mode_errorstr = INVALID_STRING_ID; } virtual EventState OnKeyPress(uint16 key, uint16 keycode) diff --git a/src/openttd.cpp b/src/openttd.cpp index 73c3b2e5b..ef7e356ea 100644 --- a/src/openttd.cpp +++ b/src/openttd.cpp @@ -1103,6 +1103,7 @@ void SwitchToMode(SwitchMode new_mode) if (_switch_mode_errorstr != INVALID_STRING_ID) { ShowErrorMessage(_switch_mode_errorstr, INVALID_STRING_ID, WL_CRITICAL); + _switch_mode_errorstr = INVALID_STRING_ID; } } -- cgit v1.2.3-70-g09d2