Backends: ensure that ImGuiPlatformMonitor list is available after backend Init call. (#7995)

This commit is contained in:
ocornut
2024-09-19 14:25:01 +02:00
parent ae8688974b
commit 42272505c9
5 changed files with 12 additions and 4 deletions

View File

@@ -649,7 +649,8 @@ static bool ImGui_ImplGlfw_Init(GLFWwindow* window, bool install_callbacks, Glfw
if (install_callbacks)
ImGui_ImplGlfw_InstallCallbacks(window);
// Update monitors the first time (note: monitor callback are broken in GLFW 3.2 and earlier, see github.com/glfw/glfw/issues/784)
// Update monitor a first time during init
// (note: monitor callback are broken in GLFW 3.2 and earlier, see github.com/glfw/glfw/issues/784)
ImGui_ImplGlfw_UpdateMonitors();
glfwSetMonitorCallback(ImGui_ImplGlfw_MonitorCallback);