Skip to content
Permalink
Browse files

Added SDL_BUTTON_WHEELUP (4) and SDL_BUTTON_WHEELDOWN (5)

  • Loading branch information
slouken committed Aug 19, 2002
1 parent 11d0bc4 commit 0884fcf07adce3700b6831c9088a3d4f640df708
Showing with 12 additions and 2 deletions.
  1. +5 −0 WhatsNew
  2. +1 −0 docs.html
  3. +4 −0 include/SDL_mouse.h
  4. +2 −2 src/video/wincommon/SDL_sysevents.c
@@ -3,6 +3,11 @@ This is a list of API changes in SDL's version history.

Version 1.0:

1.2.5:
Added SDL_BUTTON_WHEELUP (4) and SDL_BUTTON_WHEELDOWN (5)

Added SDL_GL_STEREO for stereoscopic OpenGL contexts

1.2.0:
Added SDL_VIDEOEXPOSE event to signal that the screen needs to
be redrawn. This is currently only delivered to OpenGL windows
@@ -16,6 +16,7 @@ <H2>
Major changes since SDL 1.0.0:
</H2>
<UL>
<LI> 1.2.5: Added SDL_BUTTON_WHEELUP (4) and SDL_BUTTON_WHEELDOWN (5)
<LI> 1.2.5: Added SDL_GL_STEREO for stereoscopic OpenGL contexts
<LI> 1.2.5: Fixed VidMode error when running on XFree86 3.3
<LI> 1.2.5: Added initial support for PicoGUI (thanks Micah!)
@@ -117,11 +117,15 @@ extern DECLSPEC int SDLCALL SDL_ShowCursor(int toggle);
Button 1: Left mouse button
Button 2: Middle mouse button
Button 3: Right mouse button
Button 4: Mouse wheel up (may also be a real button)
Button 5: Mouse wheel down (may also be a real button)
*/
#define SDL_BUTTON(X) (SDL_PRESSED<<(X-1))
#define SDL_BUTTON_LEFT 1
#define SDL_BUTTON_MIDDLE 2
#define SDL_BUTTON_RIGHT 3
#define SDL_BUTTON_WHEELUP 4
#define SDL_BUTTON_WHEELDOWN 5
#define SDL_BUTTON_LMASK SDL_BUTTON(SDL_BUTTON_LEFT)
#define SDL_BUTTON_MMASK SDL_BUTTON(SDL_BUTTON_MIDDLE)
#define SDL_BUTTON_RMASK SDL_BUTTON(SDL_BUTTON_RIGHT)
@@ -370,9 +370,9 @@ LONG CALLBACK WinMessage(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
if ( move ) {
Uint8 button;
if ( move > 0 )
button = 4;
button = SDL_BUTTON_WHEELUP;
else
button = 5;
button = SDL_BUTTON_WHEELDOWN;
posted = SDL_PrivateMouseButton(
SDL_PRESSED, button, 0, 0);
posted |= SDL_PrivateMouseButton(

0 comments on commit 0884fcf

Please sign in to comment.