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

Added missing X1/X2 button support

  • Loading branch information
slouken committed Aug 25, 2008
1 parent b60dfec commit 58d33afb929fe1c49acd5a2797085280832779fb
Showing with 10 additions and 0 deletions.
  1. +10 −0 src/video/win32/SDL_win32events.c
@@ -271,6 +271,16 @@ WIN_WindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
} else if (flags & RI_MOUSE_BUTTON_3_UP) {
SDL_SendMouseButton(index, SDL_RELEASED, SDL_BUTTON_RIGHT);
}
if (flags & RI_MOUSE_BUTTON_4_DOWN) {
SDL_SendMouseButton(index, SDL_PRESSED, SDL_BUTTON_X1);
} else if (flags & RI_MOUSE_BUTTON_4_UP) {
SDL_SendMouseButton(index, SDL_RELEASED, SDL_BUTTON_X1);
}
if (flags & RI_MOUSE_BUTTON_5_DOWN) {
SDL_SendMouseButton(index, SDL_PRESSED, SDL_BUTTON_X2);
} else if (flags & RI_MOUSE_BUTTON_5_UP) {
SDL_SendMouseButton(index, SDL_RELEASED, SDL_BUTTON_X2);
}
if (flags & RI_MOUSE_WHEEL) {
if (raw->data.mouse.usButtonData != 0) {
SDL_SendMouseWheel(index, 0,

0 comments on commit 58d33af

Please sign in to comment.