0x004C6118
| 107 | |
| 108 | // 0x004C6118 |
| 109 | void update() |
| 110 | { |
| 111 | uint16_t timeSinceLastTick = getTimeSinceLastTick(); |
| 112 | ToolTip::setNotShownTicks(ToolTip::getNotShownTicks() + timeSinceLastTick); |
| 113 | |
| 114 | // 1000 tick update |
| 115 | _thousandthTickCounter += timeSinceLastTick; |
| 116 | if (_thousandthTickCounter >= 1000) |
| 117 | { |
| 118 | _thousandthTickCounter = 0; |
| 119 | std::for_each(_windows.rbegin(), _windows.rend(), [](Ui::Window& w) { |
| 120 | w.callOnPeriodicUpdate(); |
| 121 | }); |
| 122 | } |
| 123 | |
| 124 | // Border flash invalidation |
| 125 | std::for_each(_windows.rbegin(), _windows.rend(), [](Ui::Window& w) { |
| 126 | if (w.hasFlags(WindowFlags::whiteBorderMask)) |
| 127 | { |
| 128 | // TODO: Replace with countdown |
| 129 | // Countdown is stuffed into WindowFlags extract it out and decrement by 1 |
| 130 | const auto newCount = enumValue(w.flags & WindowFlags::whiteBorderMask) - enumValue(WindowFlags::whiteBorderOne); |
| 131 | // Stuff the new count back into the WindowFlags |
| 132 | w.flags &= ~WindowFlags::whiteBorderMask; |
| 133 | w.flags |= static_cast<WindowFlags>(newCount); |
| 134 | |
| 135 | if (!w.hasFlags(WindowFlags::whiteBorderMask)) |
| 136 | { |
| 137 | w.invalidate(); |
| 138 | } |
| 139 | } |
| 140 | }); |
| 141 | } |
| 142 | |
| 143 | // 0x00439BA5 |
| 144 | void updateDaily() |
nothing calls this directly
no test coverage detected