mirror of
https://github.com/kovidgoyal/kitty
synced 2026-07-07 00:15:12 +02:00
Wayland: Don't insert the same monitor twice if the done event for an output is sent twice
This commit is contained in:
3
glfw/wl_monitor.c
vendored
3
glfw/wl_monitor.c
vendored
@@ -85,6 +85,9 @@ static void outputHandleMode(void* data,
|
||||
static void outputHandleDone(void* data, struct wl_output* output)
|
||||
{
|
||||
struct _GLFWmonitor *monitor = data;
|
||||
for (int i = 0; i < _glfw.monitorCount; i++) {
|
||||
if (_glfw.monitors[i] == monitor) return;
|
||||
}
|
||||
|
||||
_glfwInputMonitor(monitor, GLFW_CONNECTED, _GLFW_INSERT_LAST);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user