/** Container for any custom data that must be deleted after the news item has reached end-of-life. */
structNewsAllocatedData{
virtual~NewsAllocatedData(){}
};
/** Information about a single item of news. */
structNewsItem{
NewsItem*prev;///< Previous news item
@ -129,23 +135,29 @@ struct NewsItem {
uint32ref1;///< Reference 1 to some object: Used for a possible viewport, scrolling after clicking on the news, and for deleting the news when the object is deleted.
uint32ref2;///< Reference 2 to some object: Used for scrolling after clicking on the news, and for deleting the news when the object is deleted.
void*free_data;///< Data to be freed when the news item has reached its end.
constNewsAllocatedData*data;///< Custom data for the news item that have to be deallocated (deleted) when the news item has reached its end.
~NewsItem()
{
free(this->free_data);
deletethis->data;
}
uint64params[10];///< Parameters for string resolving.
};
/** Container for a single string to be passed as NewsAllocatedData. */