From 7be9e87ef18f9f7b91b72cfdffdf1de0de75fbb0 Mon Sep 17 00:00:00 2001 From: Camilla Berglund Date: Sun, 2 Dec 2012 16:45:03 +0100 Subject: [PATCH] Removed bad use of glfwGetCurrentContext. --- tests/joysticks.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/joysticks.c b/tests/joysticks.c index c1abb5f8..9b03a3b7 100644 --- a/tests/joysticks.c +++ b/tests/joysticks.c @@ -94,11 +94,11 @@ static void draw_joystick(Joystick* j, int x, int y, int width, int height) } } -static void draw_joysticks(void) +static void draw_joysticks(GLFWwindow window) { int i, width, height; - glfwGetWindowSize(glfwGetCurrentContext(), &width, &height); + glfwGetWindowSize(window, &width, &height); glMatrixMode(GL_PROJECTION); glLoadIdentity(); @@ -205,7 +205,7 @@ int main(void) glClear(GL_COLOR_BUFFER_BIT); refresh_joysticks(); - draw_joysticks(); + draw_joysticks(window); glfwSwapBuffers(window); glfwPollEvents();