MCPcopy Create free account
hub / github.com/Overload-Technologies/Overload / BeginPopupMenuEx

Method BeginPopupMenuEx

Dependencies/ImGui/src/imgui.cpp:12413–12430  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

12411}
12412
12413bool ImGui::BeginPopupMenuEx(ImGuiID id, const char* label, ImGuiWindowFlags extra_window_flags)
12414{
12415 ImGuiContext& g = *GImGui;
12416 if (!IsPopupOpen(id, ImGuiPopupFlags_None))
12417 {
12418 g.NextWindowData.ClearFlags(); // We behave like Begin() and need to consume those values
12419 return false;
12420 }
12421
12422 char name[128];
12423 IM_ASSERT(extra_window_flags & ImGuiWindowFlags_ChildMenu);
12424 ImFormatString(name, IM_ARRAYSIZE(name), "%s###Menu_%02d", label, g.BeginMenuDepth); // Recycle windows based on depth
12425 bool is_open = Begin(name, NULL, extra_window_flags | ImGuiWindowFlags_Popup);
12426 if (!is_open) // NB: Begin can return false when the popup is completely clipped (e.g. zero size display)
12427 EndPopup();
12428 //g.CurrentWindow->FocusRouteParentWindow = g.CurrentWindow->ParentWindowInBeginStack;
12429 return is_open;
12430}
12431
12432bool ImGui::BeginPopup(const char* str_id, ImGuiWindowFlags flags)
12433{

Callers

nothing calls this directly

Calls 2

ImFormatStringFunction · 0.85
ClearFlagsMethod · 0.45

Tested by

no test coverage detected