(svn r17200) -Codechange: Initialize NewsWindow::duration, add some documentation strings.

replace/41b28d7194a279bdc17475d4fbe2ea6ec885a466
alberth 15 years ago
parent 3409385e1d
commit 66e98469bb

@ -178,10 +178,11 @@ enum NewsTypeWidgets {
NTW_VIEWPORT, ///< Viewport in window. Only used in type0-news.
};
/** Window class displaying a news item. */
struct NewsWindow : Window {
uint16 chat_height;
NewsItem *ni;
static uint duration;
uint16 chat_height; ///< Height of the chat window.
NewsItem *ni; ///< News item to display.
static uint duration; ///< Remaining time for showing current news message (may only be accessed while a news item is displayed).
NewsWindow(const WindowDesc *desc, NewsItem *ni) : Window(desc), ni(ni)
{
@ -325,7 +326,7 @@ struct NewsWindow : Window {
}
};
/* static */ uint NewsWindow::duration; ///< Remaining time for showing current news message
/* static */ uint NewsWindow::duration = 0; // Instance creation.
static const Widget _normal_news_widgets[] = {
@ -470,6 +471,7 @@ void InitNewsItemStructs()
_latest_news = NULL;
_forced_news = NULL;
_current_news = NULL;
NewsWindow::duration = 0;
}
/**

Loading…
Cancel
Save