| 4851 | } |
| 4852 | |
| 4853 | static ImVec2 CalcWindowContentSize(ImGuiWindow* window) |
| 4854 | { |
| 4855 | if (window->Collapsed) |
| 4856 | if (window->AutoFitFramesX <= 0 && window->AutoFitFramesY <= 0) |
| 4857 | return window->ContentSize; |
| 4858 | if (window->Hidden && window->HiddenFramesCannotSkipItems == 0 && window->HiddenFramesCanSkipItems > 0) |
| 4859 | return window->ContentSize; |
| 4860 | |
| 4861 | ImVec2 sz; |
| 4862 | sz.x = IM_FLOOR((window->ContentSizeExplicit.x != 0.0f) ? window->ContentSizeExplicit.x : window->DC.CursorMaxPos.x - window->DC.CursorStartPos.x); |
| 4863 | sz.y = IM_FLOOR((window->ContentSizeExplicit.y != 0.0f) ? window->ContentSizeExplicit.y : window->DC.CursorMaxPos.y - window->DC.CursorStartPos.y); |
| 4864 | return sz; |
| 4865 | } |
| 4866 | |
| 4867 | static ImVec2 CalcWindowAutoFitSize(ImGuiWindow* window, const ImVec2& size_contents) |
| 4868 | { |
no outgoing calls
no test coverage detected