mirror of
https://github.com/ocornut/imgui.git
synced 2025-02-17 19:09:27 +01:00
Fixed hovering over a popup's child (popups disable hovering on other windows but not their childs) #197
This commit is contained in:
parent
f400ea4ec8
commit
aca85dbea4
@ -4356,9 +4356,11 @@ static inline bool IsWindowContentHoverable(ImGuiWindow* window)
|
|||||||
{
|
{
|
||||||
ImGuiState& g = *GImGui;
|
ImGuiState& g = *GImGui;
|
||||||
|
|
||||||
ImGuiWindow* focused_window = g.FocusedWindow;
|
// An active popup disable hovering on other windows (apart from its own children)
|
||||||
if (focused_window && (focused_window->Flags & ImGuiWindowFlags_Popup) != 0 && focused_window->WasVisible && focused_window != window)
|
if (ImGuiWindow* focused_window = g.FocusedWindow)
|
||||||
return false;
|
if (ImGuiWindow* focused_root_window = focused_window->RootWindow)
|
||||||
|
if ((focused_root_window->Flags & ImGuiWindowFlags_Popup) != 0 && focused_root_window->WasVisible && focused_root_window != window->RootWindow)
|
||||||
|
return false;
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user