mirror of
https://github.com/Drezil/imgui.git
synced 2024-12-19 06:26:35 +00:00
Docking: Fixed node merging altering window position incorrectly in a way that would make SizeContents incorrect for the next frame (making scrollbar flicker). (#2414, #2109)
This commit is contained in:
parent
3ead9820f7
commit
e1acb0b1fa
@ -11536,8 +11536,8 @@ static void ImGui::DockNodeApplyPosSizeToWindows(ImGuiDockNode* node)
|
|||||||
{
|
{
|
||||||
for (int n = 0; n < node->Windows.Size; n++)
|
for (int n = 0; n < node->Windows.Size; n++)
|
||||||
{
|
{
|
||||||
node->Windows[n]->Pos = node->Pos;
|
SetWindowPos(node->Windows[n], node->Pos, ImGuiCond_Always); // We don't assign directly to Pos because it can break the calculation of SizeContents on next frame
|
||||||
node->Windows[n]->SizeFull = node->Size;
|
SetWindowSize(node->Windows[n], node->Size, ImGuiCond_Always);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user