From bfe55118dd7d8af28bf8bfc84ed238e063208ab2 Mon Sep 17 00:00:00 2001 From: Camilla Berglund Date: Tue, 7 Jul 2015 11:45:53 +0200 Subject: [PATCH] Fixed name of Win32 cursor tracking flag. --- src/win32_platform.h | 2 +- src/win32_window.c | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/win32_platform.h b/src/win32_platform.h index 9bb49f16..e8e32dfc 100644 --- a/src/win32_platform.h +++ b/src/win32_platform.h @@ -151,7 +151,7 @@ typedef struct _GLFWwindowWin32 { HWND handle; - GLboolean cursorInside; + GLboolean cursorTracked; GLboolean iconified; // The last received cursor position, regardless of source diff --git a/src/win32_window.c b/src/win32_window.c index bdb3359a..8e65b450 100644 --- a/src/win32_window.c +++ b/src/win32_window.c @@ -475,7 +475,7 @@ static LRESULT CALLBACK windowProc(HWND hWnd, UINT uMsg, window->win32.cursorPosX = x; window->win32.cursorPosY = y; - if (!window->win32.cursorInside) + if (!window->win32.cursorTracked) { TRACKMOUSEEVENT tme; ZeroMemory(&tme, sizeof(tme)); @@ -484,7 +484,7 @@ static LRESULT CALLBACK windowProc(HWND hWnd, UINT uMsg, tme.hwndTrack = window->win32.handle; TrackMouseEvent(&tme); - window->win32.cursorInside = GL_TRUE; + window->win32.cursorTracked = GL_TRUE; _glfwInputCursorEnter(window, GL_TRUE); } @@ -493,7 +493,7 @@ static LRESULT CALLBACK windowProc(HWND hWnd, UINT uMsg, case WM_MOUSELEAVE: { - window->win32.cursorInside = GL_FALSE; + window->win32.cursorTracked = GL_FALSE; _glfwInputCursorEnter(window, GL_FALSE); return 0; } @@ -1196,7 +1196,7 @@ void _glfwPlatformSetCursor(_GLFWwindow* window, _GLFWcursor* cursor) if (_glfw.cursorWindow == window && window->cursorMode == GLFW_CURSOR_NORMAL && - window->win32.cursorInside) + window->win32.cursorTracked) { if (cursor) SetCursor(cursor->win32.handle);