Implement the timer class

Support calling ShowNetStartPane multiple times
This commit is contained in:
Magnus Norddahl 2023-12-31 06:36:26 +01:00
commit 9040ad62ef
8 changed files with 93 additions and 8 deletions

View file

@ -30,6 +30,16 @@ Size DisplayWindow::GetScreenSize()
return Win32Window::GetScreenSize();
}
void* DisplayWindow::StartTimer(int timeoutMilliseconds, std::function<void()> onTimer)
{
return Win32Window::StartTimer(timeoutMilliseconds, std::move(onTimer));
}
void DisplayWindow::StopTimer(void* timerID)
{
Win32Window::StopTimer(timerID);
}
#else
std::unique_ptr<DisplayWindow> DisplayWindow::Create(DisplayWindowHost* windowHost)
@ -57,4 +67,14 @@ Size DisplayWindow::GetScreenSize()
throw std::runtime_error("DisplayWindow::GetScreenSize not implemented");
}
int DisplayWindow::StartTimer(int timeoutMilliseconds, std::function<void()> onTimer)
{
throw std::runtime_error("DisplayWindow::StartTimer not implemented");
}
void DisplayWindow::StopTimer(int timerID)
{
throw std::runtime_error("DisplayWindow::StopTimer not implemented");
}
#endif