aboutsummaryrefslogtreecommitdiff
path: root/src/win/native/window.cpp
diff options
context:
space:
mode:
authorcrupest <crupest@outlook.com>2020-01-01 22:52:01 +0800
committercrupest <crupest@outlook.com>2020-01-01 22:52:01 +0800
commit36708e88596364e81dc9ba2fd3cbddbcaedeedc0 (patch)
tree0c7990b9e64c6ea1e9df7c01f3521c4fbf7ea2a0 /src/win/native/window.cpp
parentae6f797561cdfa438ebef1fbbf94d784d315e655 (diff)
downloadcru-36708e88596364e81dc9ba2fd3cbddbcaedeedc0.tar.gz
cru-36708e88596364e81dc9ba2fd3cbddbcaedeedc0.tar.bz2
cru-36708e88596364e81dc9ba2fd3cbddbcaedeedc0.zip
...
Diffstat (limited to 'src/win/native/window.cpp')
-rw-r--r--src/win/native/window.cpp13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/win/native/window.cpp b/src/win/native/window.cpp
index d3c12a44..a8016676 100644
--- a/src/win/native/window.cpp
+++ b/src/win/native/window.cpp
@@ -155,6 +155,7 @@ bool WinNativeWindow::ReleaseMouse() {
void WinNativeWindow::RequestRepaint() {
if (IsValid()) {
+ log::Debug("A repaint is requested.");
if (!::InvalidateRect(hwnd_, nullptr, FALSE))
throw Win32Error(::GetLastError(), "Failed to invalidate window.");
if (!::UpdateWindow(hwnd_))
@@ -262,7 +263,7 @@ bool WinNativeWindow::HandleNativeWindowMessage(HWND hwnd, UINT msg,
POINT point;
point.x = GET_X_LPARAM(l_param);
point.y = GET_Y_LPARAM(l_param);
- OnMouseDownInternal(platform::native::MouseButton::Left, point);
+ OnMouseDownInternal(platform::native::mouse_buttons::left, point);
*result = 0;
return true;
}
@@ -270,7 +271,7 @@ bool WinNativeWindow::HandleNativeWindowMessage(HWND hwnd, UINT msg,
POINT point;
point.x = GET_X_LPARAM(l_param);
point.y = GET_Y_LPARAM(l_param);
- OnMouseUpInternal(platform::native::MouseButton::Left, point);
+ OnMouseUpInternal(platform::native::mouse_buttons::left, point);
*result = 0;
return true;
}
@@ -278,7 +279,7 @@ bool WinNativeWindow::HandleNativeWindowMessage(HWND hwnd, UINT msg,
POINT point;
point.x = GET_X_LPARAM(l_param);
point.y = GET_Y_LPARAM(l_param);
- OnMouseDownInternal(platform::native::MouseButton::Right, point);
+ OnMouseDownInternal(platform::native::mouse_buttons::right, point);
*result = 0;
return true;
}
@@ -286,7 +287,7 @@ bool WinNativeWindow::HandleNativeWindowMessage(HWND hwnd, UINT msg,
POINT point;
point.x = GET_X_LPARAM(l_param);
point.y = GET_Y_LPARAM(l_param);
- OnMouseUpInternal(platform::native::MouseButton::Right, point);
+ OnMouseUpInternal(platform::native::mouse_buttons::right, point);
*result = 0;
return true;
}
@@ -294,7 +295,7 @@ bool WinNativeWindow::HandleNativeWindowMessage(HWND hwnd, UINT msg,
POINT point;
point.x = GET_X_LPARAM(l_param);
point.y = GET_Y_LPARAM(l_param);
- OnMouseDownInternal(platform::native::MouseButton::Middle, point);
+ OnMouseDownInternal(platform::native::mouse_buttons::middle, point);
*result = 0;
return true;
}
@@ -302,7 +303,7 @@ bool WinNativeWindow::HandleNativeWindowMessage(HWND hwnd, UINT msg,
POINT point;
point.x = GET_X_LPARAM(l_param);
point.y = GET_Y_LPARAM(l_param);
- OnMouseUpInternal(platform::native::MouseButton::Middle, point);
+ OnMouseUpInternal(platform::native::mouse_buttons::middle, point);
*result = 0;
return true;
}