MCPcopy Create free account
hub / github.com/Wemino/MarkerPatch / IsPopupOpenRequestForWindow

Method IsPopupOpenRequestForWindow

include/imgui/imgui.cpp:12609–12620  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

12607}
12608
12609bool ImGui::IsPopupOpenRequestForWindow(ImGuiPopupFlags popup_flags)
12610{
12611 ImGuiContext& g = *GImGui;
12612 ImGuiMouseButton mouse_button = GetMouseButtonFromPopupFlags(popup_flags);
12613 if (IsMouseReleased(mouse_button) && IsWindowHovered(ImGuiHoveredFlags_AllowWhenBlockedByPopup))
12614 if (!(popup_flags & ImGuiPopupFlags_NoOpenOverItems) || !IsAnyItemHovered())
12615 return true;
12616 if (g.NavOpenContextMenuWindowId && g.CurrentWindow->ID)
12617 if (IsWindowChildOf(g.NavWindow, g.CurrentWindow, false)) // This enable ordering to be used to disambiguate item vs window (#8803)
12618 return true;
12619 return false;
12620}
12621
12622// Helper to open a popup if mouse button is released over the item
12623// - This is essentially the same as BeginPopupContextItem() but without the trailing BeginPopup()

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected