Codechange: migrate all Window-related timers to the new framework

This means we also say goodbye to GUITimers.
This commit is contained in:
Patric Stout
2023-04-13 17:18:27 +02:00
committed by Patric Stout
parent 5e1bcee39b
commit 1ba4dcc924
29 changed files with 259 additions and 336 deletions

View File

@@ -27,6 +27,8 @@
#include "transparency.h"
#include "gui.h"
#include "signs_cmd.h"
#include "timer/timer.h"
#include "timer/timer_window.h"
#include "widgets/sign_widget.h"
@@ -312,11 +314,11 @@ struct SignListWindow : Window, SignList {
this->SortSignsList();
}
void OnHundredthTick() override
{
/** Resort the sign listing on a regular interval. */
IntervalTimer<TimerWindow> rebuild_interval = {std::chrono::seconds(3), [this](auto) {
this->BuildSortSignList();
this->SetDirty();
}
}};
/**
* Some data on this window has become invalid.