Browse Source

Win32: Update all monitor handles on config change

Closes #1761.
Doug Binks 5 years ago
parent
commit
166611cef5
1 changed files with 2 additions and 0 deletions
  1. 2 0
      src/win32_monitor.c

+ 2 - 0
src/win32_monitor.c

@@ -185,6 +185,8 @@ void _glfwPollMonitorsWin32(void)
                            display.DeviceName) == 0)
                 {
                     disconnected[i] = NULL;
+                    // handle may have changed, update
+                    EnumDisplayMonitors(NULL, NULL, monitorCallback, (LPARAM) _glfw.monitors[i]);
                     break;
                 }
             }