| 13225 | } |
| 13226 | |
| 13227 | bool ImGui::IsPopupOpenRequestForWindow(ImGuiPopupFlags popup_flags) |
| 13228 | { |
| 13229 | ImGuiContext& g = *GImGui; |
| 13230 | ImGuiMouseButton mouse_button = GetMouseButtonFromPopupFlags(popup_flags); |
| 13231 | if (IsMouseReleased(mouse_button) && IsWindowHovered(ImGuiHoveredFlags_AllowWhenBlockedByPopup)) |
| 13232 | if (!(popup_flags & ImGuiPopupFlags_NoOpenOverItems) || !IsAnyItemHovered()) |
| 13233 | return true; |
| 13234 | if (g.NavOpenContextMenuWindowId && g.CurrentWindow->ID) |
| 13235 | if (IsWindowChildOf(g.NavWindow, g.CurrentWindow, false, false)) // This enable ordering to be used to disambiguate item vs window (#8803) |
| 13236 | return true; |
| 13237 | return false; |
| 13238 | } |
| 13239 | |
| 13240 | // Helper to open a popup if mouse button is released over the item |
| 13241 | // - This is essentially the same as BeginPopupContextItem() but without the trailing BeginPopup() |
nothing calls this directly
no outgoing calls
no test coverage detected