Added SDL_BUTTON_WHEELUP (4) and SDL_BUTTON_WHEELDOWN (5)
authorSam Lantinga <slouken@libsdl.org>
Mon, 19 Aug 2002 18:09:44 +0000
changeset 45124edec3cafe4
parent 450 8a43e0cbf02f
child 452 4c5c10383201
Added SDL_BUTTON_WHEELUP (4) and SDL_BUTTON_WHEELDOWN (5)
WhatsNew
docs.html
include/SDL_mouse.h
src/video/wincommon/SDL_sysevents.c
     1.1 --- a/WhatsNew	Mon Aug 19 17:58:08 2002 +0000
     1.2 +++ b/WhatsNew	Mon Aug 19 18:09:44 2002 +0000
     1.3 @@ -3,6 +3,11 @@
     1.4  
     1.5  Version 1.0:
     1.6  
     1.7 +1.2.5:
     1.8 +	Added SDL_BUTTON_WHEELUP (4) and SDL_BUTTON_WHEELDOWN (5)
     1.9 +
    1.10 +	Added SDL_GL_STEREO for stereoscopic OpenGL contexts
    1.11 +
    1.12  1.2.0:
    1.13  	Added SDL_VIDEOEXPOSE event to signal that the screen needs to
    1.14  	be redrawn.  This is currently only delivered to OpenGL windows
     2.1 --- a/docs.html	Mon Aug 19 17:58:08 2002 +0000
     2.2 +++ b/docs.html	Mon Aug 19 18:09:44 2002 +0000
     2.3 @@ -16,6 +16,7 @@
     2.4  Major changes since SDL 1.0.0:
     2.5  </H2>
     2.6  <UL>
     2.7 +	<LI> 1.2.5: Added SDL_BUTTON_WHEELUP (4) and SDL_BUTTON_WHEELDOWN (5)
     2.8  	<LI> 1.2.5: Added SDL_GL_STEREO for stereoscopic OpenGL contexts
     2.9  	<LI> 1.2.5: Fixed VidMode error when running on XFree86 3.3
    2.10  	<LI> 1.2.5: Added initial support for PicoGUI (thanks Micah!)
     3.1 --- a/include/SDL_mouse.h	Mon Aug 19 17:58:08 2002 +0000
     3.2 +++ b/include/SDL_mouse.h	Mon Aug 19 18:09:44 2002 +0000
     3.3 @@ -117,11 +117,15 @@
     3.4     Button 1:	Left mouse button
     3.5     Button 2:	Middle mouse button
     3.6     Button 3:	Right mouse button
     3.7 +   Button 4:	Mouse wheel up	 (may also be a real button)
     3.8 +   Button 5:	Mouse wheel down (may also be a real button)
     3.9   */
    3.10  #define SDL_BUTTON(X)		(SDL_PRESSED<<(X-1))
    3.11  #define SDL_BUTTON_LEFT		1
    3.12  #define SDL_BUTTON_MIDDLE	2
    3.13  #define SDL_BUTTON_RIGHT	3
    3.14 +#define SDL_BUTTON_WHEELUP	4
    3.15 +#define SDL_BUTTON_WHEELDOWN	5
    3.16  #define SDL_BUTTON_LMASK	SDL_BUTTON(SDL_BUTTON_LEFT)
    3.17  #define SDL_BUTTON_MMASK	SDL_BUTTON(SDL_BUTTON_MIDDLE)
    3.18  #define SDL_BUTTON_RMASK	SDL_BUTTON(SDL_BUTTON_RIGHT)
     4.1 --- a/src/video/wincommon/SDL_sysevents.c	Mon Aug 19 17:58:08 2002 +0000
     4.2 +++ b/src/video/wincommon/SDL_sysevents.c	Mon Aug 19 18:09:44 2002 +0000
     4.3 @@ -370,9 +370,9 @@
     4.4  				if ( move ) {
     4.5  					Uint8 button;
     4.6  					if ( move > 0 )
     4.7 -						button = 4;
     4.8 +						button = SDL_BUTTON_WHEELUP;
     4.9  					else
    4.10 -						button = 5;
    4.11 +						button = SDL_BUTTON_WHEELDOWN;
    4.12  					posted = SDL_PrivateMouseButton(
    4.13  						SDL_PRESSED, button, 0, 0);
    4.14  					posted |= SDL_PrivateMouseButton(