Window: Fixed window with the AlwaysAutoResize flag unnecessarily extending their hovering boundaries by a few pixels (this is used to facilitate resizing from borders when available for a given window). One of the noticeable minor side effect was that navigating menus would have had a tendency to disable highlight from parent menu items earlier than necessary while approaching the child menu.

+ Changelog fixed unfinished sentence and tweaks,
This commit is contained in:
omar
2019-04-25 11:46:55 +02:00
parent 16b18b265e
commit 4dc4ace864
2 changed files with 14 additions and 9 deletions

View File

@ -4067,7 +4067,7 @@ static void FindHoveredWindow()
// Using the clipped AABB, a child window will typically be clipped by its parent (not always)
ImRect bb(window->OuterRectClipped);
if ((window->Flags & ImGuiWindowFlags_ChildWindow) || (window->Flags & ImGuiWindowFlags_NoResize))
if (window->Flags & (ImGuiWindowFlags_ChildWindow | ImGuiWindowFlags_NoResize | ImGuiWindowFlags_AlwaysAutoResize))
bb.Expand(padding_regular);
else
bb.Expand(padding_for_resize_from_edges);