diff options
author | glx22 <glx@openttd.org> | 2021-05-17 15:46:38 +0200 |
---|---|---|
committer | Loïc Guilloux <glx22@users.noreply.github.com> | 2021-05-29 21:08:25 +0200 |
commit | 5799402f7a4872d03809838dd7fa01db42bbd282 (patch) | |
tree | 6b54e235c14621035b4ec7923edb93980be5f056 /src/news_gui.cpp | |
parent | 994bf19aef3dde6c9482434bdc51688f76a937ea (diff) | |
download | openttd-5799402f7a4872d03809838dd7fa01db42bbd282.tar.xz |
Codechange: Rename window related DeleteXXX to match new behaviour
Diffstat (limited to 'src/news_gui.cpp')
-rw-r--r-- | src/news_gui.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/news_gui.cpp b/src/news_gui.cpp index 513624b3e..a8d7c4398 100644 --- a/src/news_gui.cpp +++ b/src/news_gui.cpp @@ -699,7 +699,7 @@ static void MoveToNextNewsItem() * there is no status bar but possible news. */ if (FindWindowById(WC_STATUS_BAR, 0) == nullptr) return; - DeleteWindowById(WC_NEWS_WINDOW, 0); // close the newspapers window if shown + CloseWindowById(WC_NEWS_WINDOW, 0); // close the newspapers window if shown _forced_news = nullptr; /* if we're not at the last item, then move on */ @@ -1010,13 +1010,13 @@ static void ShowNewsMessage(const NewsItem *ni) assert(_total_news != 0); /* Delete the news window */ - DeleteWindowById(WC_NEWS_WINDOW, 0); + CloseWindowById(WC_NEWS_WINDOW, 0); /* setup forced news item */ _forced_news = ni; if (_forced_news != nullptr) { - DeleteWindowById(WC_NEWS_WINDOW, 0); + CloseWindowById(WC_NEWS_WINDOW, 0); ShowNewspaper(ni); } } @@ -1251,6 +1251,6 @@ static WindowDesc _message_history_desc( /** Display window with news messages history */ void ShowMessageHistory() { - DeleteWindowById(WC_MESSAGE_HISTORY, 0); + CloseWindowById(WC_MESSAGE_HISTORY, 0); new MessageHistoryWindow(&_message_history_desc); } |