summaryrefslogtreecommitdiff
path: root/news_gui.c
diff options
context:
space:
mode:
authortron <tron@openttd.org>2006-03-04 11:15:44 +0000
committertron <tron@openttd.org>2006-03-04 11:15:44 +0000
commitca0862c3f4baf73549326ec2ec63ac0630cf2c95 (patch)
tree4153fe3efc35c3940fcfef3f06a03d78f4f6f97f /news_gui.c
parent332b54d5a6156c192e044163d7f38d87e2801814 (diff)
downloadopenttd-ca0862c3f4baf73549326ec2ec63ac0630cf2c95.tar.xz
(svn r3758) Remove the news validation callback. It is superseded by r3757.
Diffstat (limited to 'news_gui.c')
-rw-r--r--news_gui.c10
1 files changed, 0 insertions, 10 deletions
diff --git a/news_gui.c b/news_gui.c
index 1354983ec..4bbfe3e1b 100644
--- a/news_gui.c
+++ b/news_gui.c
@@ -275,13 +275,6 @@ void AddNewsItem(StringID string, uint32 flags, uint data_a, uint data_b)
w->vscroll.count = _total_news;
}
-/* To add a news item with an attached validation function. This validation function
- * makes sure that the news item is not outdated when the newspaper pops up. */
-void AddValidatedNewsItem(StringID string, uint32 flags, uint data_a, uint data_b, ValidationProc *validation)
-{
- AddNewsItem(string, flags, data_a, data_b);
- _news_items[_latest_news].isValid = validation;
-}
// don't show item if it's older than x days
static const byte _news_items_age[] = {60, 60, 90, 60, 90, 30, 150, 30, 90, 180};
@@ -466,9 +459,6 @@ static void MoveToNexItem(void)
// check the date, don't show too old items
if (_date - _news_items_age[ni->type] > ni->date) return;
- // execute the validation function to see if this item is still valid
- if (ni->isValid != NULL && !ni->isValid(ni->data_a, ni->data_b)) return;
-
switch (GetNewsDisplayValue(ni->type)) {
case 0: { /* Off - show nothing only a small reminder in the status bar */
Window* w = FindWindowById(WC_STATUS_BAR, 0);