Add glfwMaximizeWindow and GLFW_MAXIMIZED

Fixes #266.
This commit is contained in:
Camilla Berglund
2015-10-13 12:50:59 +02:00
parent 8c4ce9a3de
commit a10caa4631
14 changed files with 215 additions and 8 deletions

View File

@@ -62,9 +62,15 @@ static void key_callback(GLFWwindow* window, int key, int scancode, int action,
switch (key)
{
case GLFW_KEY_SPACE:
case GLFW_KEY_I:
glfwIconifyWindow(window);
break;
case GLFW_KEY_M:
glfwMaximizeWindow(window);
break;
case GLFW_KEY_R:
glfwRestoreWindow(window);
break;
case GLFW_KEY_ESCAPE:
glfwSetWindowShouldClose(window, GLFW_TRUE);
break;
@@ -240,7 +246,7 @@ int main(int argc, char** argv)
for (;;)
{
glfwPollEvents();
glfwWaitEvents();
for (i = 0; i < window_count; i++)
{