Popups: Closes popup at the time of FocusWindow(). Fixes right-click from closing all popups instead of aiming at the hovered popup level (regression in 1.67's ae76a1fd).

This commit is contained in:
omar
2019-04-28 22:21:23 +02:00
parent bda2cde68e
commit 842a720e72
4 changed files with 32 additions and 18 deletions

View File

@ -2209,6 +2209,13 @@ static void ShowDemoWindowPopups()
if (ImGui::BeginMenu("Sub-menu"))
{
ImGui::MenuItem("Click me");
if (ImGui::Button("Stacked Popup"))
ImGui::OpenPopup("another popup");
if (ImGui::BeginPopup("another popup"))
{
ImGui::Text("I am the last one here.");
ImGui::EndPopup();
}
ImGui::EndMenu();
}
ImGui::EndPopup();