Merge branch 'master' into multi-monitor

Conflicts:
	examples/wave.c
	src/init.c
	src/internal.h
	src/window.c
	tests/accuracy.c
	tests/events.c
	tests/reopen.c
This commit is contained in:
Camilla Berglund
2012-11-01 00:07:01 +01:00
28 changed files with 245 additions and 184 deletions
+7 -4
View File
@@ -127,10 +127,6 @@ static void test_modes(GLFWmonitor monitor)
int i, count;
GLFWvidmode* modes = glfwGetVideoModes(monitor, &count);
glfwSetWindowSizeCallback(window_size_callback);
glfwSetWindowCloseCallback(window_close_callback);
glfwSetKeyCallback(key_callback);
for (i = 0; i < count; i++)
{
GLFWvidmode* mode = modes + i;
@@ -157,6 +153,10 @@ static void test_modes(GLFWmonitor monitor)
continue;
}
glfwSetWindowSizeCallback(window_handle, window_size_callback);
glfwSetWindowCloseCallback(window_handle, window_close_callback);
glfwSetKeyCallback(window_handle, key_callback);
glfwMakeContextCurrent(window_handle);
glfwSwapInterval(1);
@@ -171,6 +171,8 @@ static void test_modes(GLFWmonitor monitor)
if (!window_handle)
{
printf("User terminated program\n");
glfwTerminate();
exit(EXIT_SUCCESS);
}
}
@@ -244,6 +246,7 @@ int main(int argc, char** argv)
test_modes(monitors[i]);
}
glfwTerminate();
exit(EXIT_SUCCESS);
}