mirror of
https://github.com/ocornut/imgui.git
synced 2026-02-05 04:10:07 +00:00
Window: Fixed initial width of collapsed windows not taking account of contents width (broken in 1.67). (#2336, #176)
This commit is contained in:
parent
1b63ded8fa
commit
afc36cf802
2 changed files with 3 additions and 1 deletions
|
|
@ -4558,7 +4558,8 @@ static ImVec2 CalcSizeAfterConstraint(ImGuiWindow* window, ImVec2 new_size)
|
|||
static ImVec2 CalcSizeContents(ImGuiWindow* window)
|
||||
{
|
||||
if (window->Collapsed)
|
||||
return window->SizeContents;
|
||||
if (window->AutoFitFramesX <= 0 && window->AutoFitFramesY <= 0)
|
||||
return window->SizeContents;
|
||||
if (window->Hidden && window->HiddenFramesForResize == 0 && window->HiddenFramesRegular > 0)
|
||||
return window->SizeContents;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue