mirror of
https://github.com/Drezil/imgui.git
synced 2024-11-15 09:27:00 +00:00
Viewport: Avoid creating viewport on drag (fix cc882b0723
)
This commit is contained in:
parent
3b9b1956cd
commit
7b433605f9
@ -6229,6 +6229,7 @@ static void ImGui::UpdateSelectWindowViewport(ImGuiWindow* window)
|
|||||||
}
|
}
|
||||||
else if (!window->ViewportOwned && g.MovingWindow && g.MovingWindow->RootWindow == window && IsMousePosValid())
|
else if (!window->ViewportOwned && g.MovingWindow && g.MovingWindow->RootWindow == window && IsMousePosValid())
|
||||||
{
|
{
|
||||||
|
if (!window->Viewport->GetRect().Contains(window->Rect()))
|
||||||
window->Viewport = AddUpdateViewport(window, window->ID, window->Pos, window->Size, ImGuiViewportFlags_NoDecoration | ImGuiViewportFlags_NoFocusOnAppearing | ImGuiViewportFlags_NoInputs);
|
window->Viewport = AddUpdateViewport(window, window->ID, window->Pos, window->Size, ImGuiViewportFlags_NoDecoration | ImGuiViewportFlags_NoFocusOnAppearing | ImGuiViewportFlags_NoInputs);
|
||||||
}
|
}
|
||||||
else if (!window->ViewportOwned && GetWindowAlwaysWantOwnViewport(window))
|
else if (!window->ViewportOwned && GetWindowAlwaysWantOwnViewport(window))
|
||||||
|
Loading…
Reference in New Issue
Block a user