1
0
mirror of https://github.com/ocornut/imgui.git synced 2024-11-16 20:07:18 +01:00

Docking: fixed potential crash if a passthrough dock node is submitted without a child intermediate (currently not possible via API)

This commit is contained in:
ocornut 2022-02-03 12:04:11 +01:00
parent 5017602752
commit 31762a8173

View File

@ -14979,6 +14979,7 @@ static void ImGui::DockNodeUpdate(ImGuiDockNode* node)
if (central_node_hole && !hole_rect.IsInverted()) if (central_node_hole && !hole_rect.IsInverted())
{ {
SetWindowHitTestHole(host_window, hole_rect.Min, hole_rect.Max - hole_rect.Min); SetWindowHitTestHole(host_window, hole_rect.Min, hole_rect.Max - hole_rect.Min);
if (host_window->ParentWindow)
SetWindowHitTestHole(host_window->ParentWindow, hole_rect.Min, hole_rect.Max - hole_rect.Min); SetWindowHitTestHole(host_window->ParentWindow, hole_rect.Min, hole_rect.Max - hole_rect.Min);
} }
} }