Popups: child popups (menus) hidden on their first frame the same way as regular popup

This commit is contained in:
ocornut 2015-05-15 20:35:28 +01:00
parent 81937d34a8
commit 70f83a3a65

View File

@ -1776,8 +1776,11 @@ static void AddWindowToRenderList(ImVector<ImDrawList*>& out_render_list, ImGuiW
for (size_t i = 0; i < window->DC.ChildWindows.size(); i++) for (size_t i = 0; i < window->DC.ChildWindows.size(); i++)
{ {
ImGuiWindow* child = window->DC.ChildWindows[i]; ImGuiWindow* child = window->DC.ChildWindows[i];
if (child->Active) // clipped children may have been marked not active if (!child->Active) // clipped children may have been marked not active
AddWindowToRenderList(out_render_list, child); continue;
if ((child->Flags & ImGuiWindowFlags_Popup) && child->HiddenFrames > 0)
continue;
AddWindowToRenderList(out_render_list, child);
} }
} }