diff --git a/imgui.cpp b/imgui.cpp index 189fa66..d40bacd 100644 --- a/imgui.cpp +++ b/imgui.cpp @@ -2802,9 +2802,7 @@ // With right mouse button we close popups without changing focus // (The left mouse button path calls FocusWindow which will lead NewFrame->CloseInactivePopups to trigger) if (g.IO.MouseClicked[1]) - { CloseInactivePopups(g.HoveredWindow); - } } } @@ -3605,8 +3603,8 @@ break; } } - if (n < g.OpenPopupStack.Size) // This test is not required but it allows to set a useful breakpoint on the line below - g.OpenPopupStack.resize(n); + if (n < g.OpenPopupStack.Size) // This test is not required but it allows to set a convenient breakpoint on the block below + ClosePopupToLevel(n); } static ImGuiWindow* GetFrontMostModalRootWindow()