Made glfwGetVideoMode consistent with getters.

This commit is contained in:
Camilla Berglund
2013-05-22 22:16:43 +02:00
parent 5d308db654
commit ce1e84def6
7 changed files with 18 additions and 19 deletions
+4 -5
View File
@@ -322,14 +322,13 @@ GLFWAPI const GLFWvidmode* glfwGetVideoModes(GLFWmonitor* handle, int* count)
return monitor->modes;
}
GLFWAPI GLFWvidmode glfwGetVideoMode(GLFWmonitor* handle)
GLFWAPI const GLFWvidmode* glfwGetVideoMode(GLFWmonitor* handle)
{
_GLFWmonitor* monitor = (_GLFWmonitor*) handle;
GLFWvidmode mode = { 0, 0, 0, 0, 0 };
_GLFW_REQUIRE_INIT_OR_RETURN(mode);
_GLFW_REQUIRE_INIT_OR_RETURN(NULL);
_glfwPlatformGetVideoMode(monitor, &mode);
return mode;
_glfwPlatformGetVideoMode(monitor, &monitor->currentMode);
return &monitor->currentMode;
}