mirror of
https://github.com/gwm17/glfw.git
synced 2025-02-07 06:38:50 -05:00
Removed function made superfluous by window struct memset.
This commit is contained in:
parent
17d9b5aa8f
commit
98eb79b7d9
35
src/window.c
35
src/window.c
|
@ -85,39 +85,6 @@ static void clearScrollOffsets(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//========================================================================
|
|
||||||
// Clear all input state for the specified window
|
|
||||||
//========================================================================
|
|
||||||
|
|
||||||
static void clearInputState(_GLFWwindow* window)
|
|
||||||
{
|
|
||||||
int i;
|
|
||||||
|
|
||||||
// Release all keyboard keys
|
|
||||||
for (i = 0; i <= GLFW_KEY_LAST; i++)
|
|
||||||
window->key[i] = GLFW_RELEASE;
|
|
||||||
|
|
||||||
// Release all mouse buttons
|
|
||||||
for (i = 0; i <= GLFW_MOUSE_BUTTON_LAST; i++)
|
|
||||||
window->mouseButton[i] = GLFW_RELEASE;
|
|
||||||
|
|
||||||
// Set mouse position to (0,0)
|
|
||||||
window->mousePosX = 0;
|
|
||||||
window->mousePosY = 0;
|
|
||||||
|
|
||||||
// Set scroll offsets to (0,0)
|
|
||||||
window->scrollX = 0;
|
|
||||||
window->scrollY = 0;
|
|
||||||
|
|
||||||
// The default is to use non sticky keys and mouse buttons
|
|
||||||
window->stickyKeys = GL_FALSE;
|
|
||||||
window->stickyMouseButtons = GL_FALSE;
|
|
||||||
|
|
||||||
// The default is to disable key repeat
|
|
||||||
window->keyRepeat = GL_FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//========================================================================
|
//========================================================================
|
||||||
// Checks whether the OpenGL part of the window config is sane
|
// Checks whether the OpenGL part of the window config is sane
|
||||||
//========================================================================
|
//========================================================================
|
||||||
|
@ -416,8 +383,6 @@ GLFWAPI GLFWwindow glfwOpenWindow(int width, int height,
|
||||||
return GL_FALSE;
|
return GL_FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
clearInputState(window);
|
|
||||||
|
|
||||||
// Check width & height
|
// Check width & height
|
||||||
if (width > 0 && height <= 0)
|
if (width > 0 && height <= 0)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue
Block a user