Merge branch 'master' into jgrpp
# Conflicts: # src/lang/afrikaans.txt # src/lang/basque.txt # src/lang/belarusian.txt # src/lang/brazilian_portuguese.txt # src/lang/bulgarian.txt # src/lang/catalan.txt # src/lang/croatian.txt # src/lang/czech.txt # src/lang/danish.txt # src/lang/dutch.txt # src/lang/english.txt # src/lang/english_AU.txt # src/lang/english_US.txt # src/lang/estonian.txt # src/lang/finnish.txt # src/lang/french.txt # src/lang/gaelic.txt # src/lang/galician.txt # src/lang/german.txt # src/lang/greek.txt # src/lang/hebrew.txt # src/lang/hungarian.txt # src/lang/icelandic.txt # src/lang/indonesian.txt # src/lang/irish.txt # src/lang/italian.txt # src/lang/japanese.txt # src/lang/korean.txt # src/lang/latin.txt # src/lang/latvian.txt # src/lang/lithuanian.txt # src/lang/luxembourgish.txt # src/lang/norwegian_bokmal.txt # src/lang/norwegian_nynorsk.txt # src/lang/polish.txt # src/lang/portuguese.txt # src/lang/romanian.txt # src/lang/russian.txt # src/lang/serbian.txt # src/lang/simplified_chinese.txt # src/lang/slovak.txt # src/lang/slovenian.txt # src/lang/spanish.txt # src/lang/spanish_MX.txt # src/lang/swedish.txt # src/lang/tamil.txt # src/lang/thai.txt # src/lang/traditional_chinese.txt # src/lang/turkish.txt # src/lang/ukrainian.txt # src/lang/unfinished/persian.txt # src/lang/vietnamese.txt # src/lang/welsh.txt # src/rail_cmd.cpp # src/station_cmd.cpp
This commit is contained in:
@@ -39,6 +39,7 @@
|
||||
#include "framerate_type.h"
|
||||
#include "network/network_func.h"
|
||||
#include "guitimer_func.h"
|
||||
#include "news_func.h"
|
||||
|
||||
#include "safeguards.h"
|
||||
|
||||
@@ -3408,6 +3409,17 @@ restart_search:
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete all messages and their corresponding window (if any).
|
||||
*/
|
||||
void DeleteAllMessages()
|
||||
{
|
||||
InitNewsItemStructs();
|
||||
InvalidateWindowData(WC_STATUS_BAR, 0, SBI_NEWS_DELETED); // invalidate the statusbar
|
||||
InvalidateWindowData(WC_MESSAGE_HISTORY, 0); // invalidate the message history
|
||||
DeleteWindowById(WC_NEWS_WINDOW, 0); // close newspaper or general message window if shown
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete all windows that are used for construction of vehicle etc.
|
||||
* Once done with that invalidate the others to ensure they get refreshed too.
|
||||
|
Reference in New Issue
Block a user