panel: a re-shown panel starts its window over #2565

Merged
sh3nw4ld merged 9 commits from upstream-pr/2565 into main 2026-11-30 14:12:02 +00:00
sh3nw4ld commented 2026-11-29 14:25:40 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by sh3nw4ld on 2026-11-29T14:25:40Z.


What this fixes

The refresh window of the F3 panel reset only after a hidden gap of over a second (frames == 0 && now - last > 2 * EVERY). Re-shown sooner, it kept the hidden time in since and last: the first line printed the gap as a frame time (LONGEST about a second a frame at a ~0.8 s hide) and spread every counter over it.

frames is zero only after a hide (or at birth), so it alone decides now: whatever the gap, the next shown frame starts the window over. The old > 2 * EVERY term was a duplicate of what the gap check was for — nothing else sets frames to zero.

Tests

a_re_shown_panel_starts_its_window_over: a run, a hide with the window frozen 800 ms in the past (EVERY is 500 ms, so the old condition does not fire), a re-show — worst is 0, not ~800. It fails on main (left 800-ish, right 0) and passes with the change.

cargo test -p victory-gpu --lib --locked panel: 9 passed, 0 failed.

Environment

Windows 11, RTX 4060 Ti, Rust 1.98.1 (pinned).

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:issue:5551648259 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/2565). Originally posted by [sh3nw4ld](https://github.com/sh3nw4ld) on 2026-11-29T14:25:40Z. --- ## What this fixes The refresh window of the F3 panel reset only after a hidden gap of over a second (`frames == 0 && now - last > 2 * EVERY`). Re-shown sooner, it kept the hidden time in `since` and `last`: the first line printed the gap as a frame time (`LONGEST` about a second a frame at a ~0.8 s hide) and spread every counter over it. `frames` is zero only after a hide (or at birth), so it alone decides now: whatever the gap, the next shown frame starts the window over. The old `> 2 * EVERY` term was a duplicate of what the gap check was for — nothing else sets `frames` to zero. ## Tests `a_re_shown_panel_starts_its_window_over`: a run, a hide with the window frozen 800 ms in the past (`EVERY` is 500 ms, so the old condition does not fire), a re-show — `worst` is 0, not ~800. It fails on main (left 800-ish, right 0) and passes with the change. `cargo test -p victory-gpu --lib --locked panel`: 9 passed, 0 failed. ## Environment Windows 11, RTX 4060 Ti, Rust 1.98.1 (pinned).
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
trustno1-coder/VIctory-NVIDIA!2565
No description provided.