ImGuiFullscreen: Allow smooth scrolling

This commit is contained in:
Stenzek
2024-09-09 21:57:08 +10:00
parent e93dea5ad8
commit 891d5cefbe
9 changed files with 74 additions and 13 deletions

View File

@@ -2618,7 +2618,8 @@ struct IMGUI_API ImGuiWindow
ImGuiID MoveId; // == window->GetID("#MOVE")
ImGuiID ChildId; // ID of corresponding item in parent window (for navigation to return from child window to parent window)
ImGuiID PopupId; // ID in the popup stack when this window is used as a popup/menu (because we use generic Name/ID for recycling)
ImVec2 Scroll;
ImVec2 Scroll; // Current Visible Scroll position
ImVec2 ScrollExpected; // Current Expected Scroll position
ImVec2 ScrollMax;
ImVec2 ScrollTarget; // target scroll position. stored as cursor position with scrolling canceled out, so the highest point is always 0.0f. (FLT_MAX for no change)
ImVec2 ScrollTargetCenterRatio; // 0.0f = scroll so that target position is at top, 0.5f = scroll so that target position is centered