0x00439AD9
| 384 | |
| 385 | // 0x00439AD9 |
| 386 | static void onUpdate(Window& w) |
| 387 | { |
| 388 | w.var_854 += 1; |
| 389 | if (w.var_854 >= 24) |
| 390 | { |
| 391 | w.var_854 = 0; |
| 392 | } |
| 393 | |
| 394 | w.numTicksVisible += 1; |
| 395 | if (w.numTicksVisible >= kPausedStatusTextDuration * 2) |
| 396 | { |
| 397 | w.numTicksVisible = 0; |
| 398 | } |
| 399 | |
| 400 | // Determine if the text needs to be updated |
| 401 | if (SceneManager::isPaused() && (SceneManager::getPauseFlags() & PauseFlags::browsePrompt) == PauseFlags::none) |
| 402 | { |
| 403 | if (w.numTicksVisible == 0 || w.numTicksVisible == kPausedStatusTextDuration) |
| 404 | { |
| 405 | redrawScheduled = true; |
| 406 | } |
| 407 | } |
| 408 | |
| 409 | if (redrawScheduled) |
| 410 | { |
| 411 | redrawScheduled = false; |
| 412 | |
| 413 | // Invalidating the inner frame widget effectively causes the entire time panel to be redrawn. |
| 414 | WindowManager::invalidateWidget(WindowType::timeToolbar, 0, Widx::inner_frame); |
| 415 | } |
| 416 | } |
| 417 | |
| 418 | static constexpr WindowEventList kEvents = { |
| 419 | .onMouseUp = onMouseUp, |
nothing calls this directly
no test coverage detected