Added OpenPopup() ImGuiID overload (#3993, #331)

This commit is contained in:
ocornut
2021-04-01 17:18:18 +02:00
parent f0fc822837
commit 00d570e280
3 changed files with 7 additions and 0 deletions

View File

@ -8093,6 +8093,11 @@ void ImGui::OpenPopup(const char* str_id, ImGuiPopupFlags popup_flags)
OpenPopupEx(g.CurrentWindow->GetID(str_id), popup_flags);
}
void ImGui::OpenPopup(ImGuiID id, ImGuiPopupFlags popup_flags)
{
OpenPopupEx(id, popup_flags);
}
// Mark popup as open (toggle toward open state).
// Popups are closed when user click outside, or activate a pressable item, or CloseCurrentPopup() is called within a BeginPopup()/EndPopup() block.
// Popup identifiers are relative to the current ID-stack (so OpenPopup and BeginPopup needs to be at the same level).