Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files

Fixed mouse wheel delta on Windows

  • Loading branch information
slouken committed Feb 12, 2013
1 parent d7d163f commit 370c5aa33fc094fed2cb0aab1ad6e47fce63df60
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/video/windows/SDL_windowsevents.c
@@ -291,7 +291,8 @@ WIN_WindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)

case WM_MOUSEWHEEL:
{
int motion = (short) HIWORD(wParam);
// FIXME: This may need to accumulate deltas up to WHEEL_DELTA
short motion = GET_WHEEL_DELTA_WPARAM(wParam) / WHEEL_DELTA;

SDL_SendMouseWheel(data->window, 0, motion);
break;

0 comments on commit 370c5aa

Please sign in to comment.