diff --git a/tests/events.c b/tests/events.c index 71f88080..d9a5eea2 100644 --- a/tests/events.c +++ b/tests/events.c @@ -476,6 +476,8 @@ int main(int argc, char** argv) printf("Library initialized\n"); + glfwSetMonitorCallback(monitor_callback); + while ((ch = getopt(argc, argv, "hfn:")) != -1) { switch (ch) @@ -557,8 +559,6 @@ int main(int argc, char** argv) glfwSetWindowUserPointer(slots[i].window, slots + i); - glfwSetMonitorCallback(monitor_callback); - glfwSetWindowPosCallback(slots[i].window, window_pos_callback); glfwSetWindowSizeCallback(slots[i].window, window_size_callback); glfwSetFramebufferSizeCallback(slots[i].window, framebuffer_size_callback);