include/SDL_mouse.h
branchSDL-1.2
changeset 4217 4c4113c2162c
parent 4159 a1b03ba2fcd0
child 6137 4720145f848b
     1.1 --- a/include/SDL_mouse.h	Mon Sep 21 09:27:08 2009 +0000
     1.2 +++ b/include/SDL_mouse.h	Mon Sep 21 09:38:10 2009 +0000
     1.3 @@ -20,7 +20,9 @@
     1.4      slouken@libsdl.org
     1.5  */
     1.6  
     1.7 -/* Include file for SDL mouse event handling */
     1.8 +/** @file SDL_mouse.h
     1.9 + *  Include file for SDL mouse event handling
    1.10 + */
    1.11  
    1.12  #ifndef _SDL_mouse_h
    1.13  #define _SDL_mouse_h
    1.14 @@ -35,18 +37,18 @@
    1.15  extern "C" {
    1.16  #endif
    1.17  
    1.18 -typedef struct WMcursor WMcursor;	/* Implementation dependent */
    1.19 +typedef struct WMcursor WMcursor;	/**< Implementation dependent */
    1.20  typedef struct SDL_Cursor {
    1.21 -	SDL_Rect area;			/* The area of the mouse cursor */
    1.22 -	Sint16 hot_x, hot_y;		/* The "tip" of the cursor */
    1.23 -	Uint8 *data;			/* B/W cursor data */
    1.24 -	Uint8 *mask;			/* B/W cursor mask */
    1.25 -	Uint8 *save[2];			/* Place to save cursor area */
    1.26 -	WMcursor *wm_cursor;		/* Window-manager cursor */
    1.27 +	SDL_Rect area;			/**< The area of the mouse cursor */
    1.28 +	Sint16 hot_x, hot_y;		/**< The "tip" of the cursor */
    1.29 +	Uint8 *data;			/**< B/W cursor data */
    1.30 +	Uint8 *mask;			/**< B/W cursor mask */
    1.31 +	Uint8 *save[2];			/**< Place to save cursor area */
    1.32 +	WMcursor *wm_cursor;		/**< Window-manager cursor */
    1.33  } SDL_Cursor;
    1.34  
    1.35  /* Function prototypes */
    1.36 -/*
    1.37 +/**
    1.38   * Retrieve the current state of the mouse.
    1.39   * The current button state is returned as a button bitmask, which can
    1.40   * be tested using the SDL_BUTTON(X) macros, and x and y are set to the
    1.41 @@ -54,7 +56,7 @@
    1.42   */
    1.43  extern DECLSPEC Uint8 SDLCALL SDL_GetMouseState(int *x, int *y);
    1.44  
    1.45 -/*
    1.46 +/**
    1.47   * Retrieve the current state of the mouse.
    1.48   * The current button state is returned as a button bitmask, which can
    1.49   * be tested using the SDL_BUTTON(X) macros, and x and y are set to the
    1.50 @@ -62,12 +64,12 @@
    1.51   */
    1.52  extern DECLSPEC Uint8 SDLCALL SDL_GetRelativeMouseState(int *x, int *y);
    1.53  
    1.54 -/*
    1.55 +/**
    1.56   * Set the position of the mouse cursor (generates a mouse motion event)
    1.57   */
    1.58  extern DECLSPEC void SDLCALL SDL_WarpMouse(Uint16 x, Uint16 y);
    1.59  
    1.60 -/*
    1.61 +/**
    1.62   * Create a cursor using the specified data and mask (in MSB format).
    1.63   * The cursor width must be a multiple of 8 bits.
    1.64   *
    1.65 @@ -83,24 +85,24 @@
    1.66  extern DECLSPEC SDL_Cursor * SDLCALL SDL_CreateCursor
    1.67  		(Uint8 *data, Uint8 *mask, int w, int h, int hot_x, int hot_y);
    1.68  
    1.69 -/*
    1.70 +/**
    1.71   * Set the currently active cursor to the specified one.
    1.72   * If the cursor is currently visible, the change will be immediately 
    1.73   * represented on the display.
    1.74   */
    1.75  extern DECLSPEC void SDLCALL SDL_SetCursor(SDL_Cursor *cursor);
    1.76  
    1.77 -/*
    1.78 +/**
    1.79   * Returns the currently active cursor.
    1.80   */
    1.81  extern DECLSPEC SDL_Cursor * SDLCALL SDL_GetCursor(void);
    1.82  
    1.83 -/*
    1.84 +/**
    1.85   * Deallocates a cursor created with SDL_CreateCursor().
    1.86   */
    1.87  extern DECLSPEC void SDLCALL SDL_FreeCursor(SDL_Cursor *cursor);
    1.88  
    1.89 -/*
    1.90 +/**
    1.91   * Toggle whether or not the cursor is shown on the screen.
    1.92   * The cursor start off displayed, but can be turned off.
    1.93   * SDL_ShowCursor() returns 1 if the cursor was being displayed
    1.94 @@ -109,12 +111,13 @@
    1.95   */
    1.96  extern DECLSPEC int SDLCALL SDL_ShowCursor(int toggle);
    1.97  
    1.98 -/* Used as a mask when testing buttons in buttonstate
    1.99 -   Button 1:	Left mouse button
   1.100 -   Button 2:	Middle mouse button
   1.101 -   Button 3:	Right mouse button
   1.102 -   Button 4:	Mouse wheel up	 (may also be a real button)
   1.103 -   Button 5:	Mouse wheel down (may also be a real button)
   1.104 +/*@{*/
   1.105 +/** Used as a mask when testing buttons in buttonstate
   1.106 + *  Button 1:	Left mouse button
   1.107 + *  Button 2:	Middle mouse button
   1.108 + *  Button 3:	Right mouse button
   1.109 + *  Button 4:	Mouse wheel up	 (may also be a real button)
   1.110 + *  Button 5:	Mouse wheel down (may also be a real button)
   1.111   */
   1.112  #define SDL_BUTTON(X)		(1 << ((X)-1))
   1.113  #define SDL_BUTTON_LEFT		1
   1.114 @@ -129,7 +132,7 @@
   1.115  #define SDL_BUTTON_RMASK	SDL_BUTTON(SDL_BUTTON_RIGHT)
   1.116  #define SDL_BUTTON_X1MASK	SDL_BUTTON(SDL_BUTTON_X1)
   1.117  #define SDL_BUTTON_X2MASK	SDL_BUTTON(SDL_BUTTON_X2)
   1.118 -
   1.119 +/*@}*/
   1.120  
   1.121  /* Ends C function definitions when using C++ */
   1.122  #ifdef __cplusplus