mirror of
https://github.com/Drezil/imgui.git
synced 2025-01-04 21:56:35 +00:00
This commit is contained in:
parent
e7577d570e
commit
b305953bd1
@ -12064,7 +12064,7 @@ const ImGuiPlatformMonitor* ImGui::GetViewportPlatformMonitor(ImGuiViewport* vie
|
|||||||
ImGuiContext& g = *GImGui;
|
ImGuiContext& g = *GImGui;
|
||||||
ImGuiViewportP* viewport = (ImGuiViewportP*)(void*)viewport_p;
|
ImGuiViewportP* viewport = (ImGuiViewportP*)(void*)viewport_p;
|
||||||
int monitor_idx = viewport->PlatformMonitor;
|
int monitor_idx = viewport->PlatformMonitor;
|
||||||
if (monitor_idx >= 0 || monitor_idx < g.PlatformIO.Monitors.Size)
|
if (monitor_idx >= 0 && monitor_idx < g.PlatformIO.Monitors.Size)
|
||||||
return &g.PlatformIO.Monitors[monitor_idx];
|
return &g.PlatformIO.Monitors[monitor_idx];
|
||||||
return &g.FallbackMonitor;
|
return &g.FallbackMonitor;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user