Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Mouse wheel fix patch.
- Loading branch information
Showing
with
8 additions
and
4 deletions.
-
+2
−0
src/video/wincommon/SDL_sysevents.c
-
+6
−4
src/video/windx5/SDL_dx5events.c
|
@@ -370,6 +370,8 @@ LONG CALLBACK WinMessage(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) |
|
|
button = 5; |
|
|
posted = SDL_PrivateMouseButton( |
|
|
SDL_PRESSED, button, 0, 0); |
|
|
posted |= SDL_PrivateMouseButton( |
|
|
SDL_RELEASED, button, 0, 0); |
|
|
} |
|
|
} |
|
|
return(0); |
|
|
|
@@ -392,11 +392,13 @@ static void handle_mouse(const int numevents, DIDEVICEOBJECTDATA *ptrbuf) |
|
|
yrel = 0; |
|
|
} |
|
|
if((int)ptrbuf[i].dwData > 0) |
|
|
button = 4; |
|
|
else |
|
|
button = 5; |
|
|
posted = SDL_PrivateMouseButton( |
|
|
SDL_PRESSED, 4, 0, 0); |
|
|
else if((int)ptrbuf[i].dwData < 0) |
|
|
posted = SDL_PrivateMouseButton( |
|
|
SDL_PRESSED, 5, 0, 0); |
|
|
SDL_PRESSED, button, 0, 0); |
|
|
posted |= SDL_PrivateMouseButton( |
|
|
SDL_RELEASED, button, 0, 0); |
|
|
break; |
|
|
case DIMOFS_BUTTON0: |
|
|
case DIMOFS_BUTTON1: |
|
|
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session.
You signed out in another tab or window. Reload to refresh your session.