mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-26 11:48:36 +01:00
Implement mousewheel vertical scroll and hover in ImGui integration
This commit is contained in:
1 parent
673c22a9c4
commit
dff7f5704a
5 files changed
+42
-21
No files matched your search
+11
-12
@@ -680,19 +680,18 @@ namespace MainWindow
|
||||
float y = (float)cursorY * g_display.dpi_scale_y;
|
||||
WindowsRawInput::SetMousePos(x, y);
|
||||
|
||||
if (wParam & (MK_LBUTTON | MK_RBUTTON)) {
|
||||
TouchInput touch{};
|
||||
touch.flags = TOUCH_MOVE | TOUCH_MOUSE;
|
||||
if (wParam & MK_LBUTTON) {
|
||||
touch.buttons |= 1;
|
||||
}
|
||||
if (wParam & MK_RBUTTON) {
|
||||
touch.buttons |= 2;
|
||||
}
|
||||
touch.x = x;
|
||||
touch.y = y;
|
||||
NativeTouch(touch);
|
||||
// Mouse moves now happen also when no button is pressed.
|
||||
TouchInput touch{};
|
||||
touch.flags = TOUCH_MOVE | TOUCH_MOUSE;
|
||||
if (wParam & MK_LBUTTON) {
|
||||
touch.buttons |= 1;
|
||||
}
|
||||
if (wParam & MK_RBUTTON) {
|
||||
touch.buttons |= 2;
|
||||
}
|
||||
touch.x = x;
|
||||
touch.y = y;
|
||||
NativeTouch(touch);
|
||||
}
|
||||
break;
|
||||
|
||||
|
||||
Reference in new issue
Block a user