00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00032 #ifndef __MLV_MOUSE_H__
00033 #define __MLV_MOUSE_H__
00034
00035 #ifndef MEMORY_DEBUG
00036 #include <SDL/SDL.h>
00037 #else
00038 #include "memory_debug.h"
00039 #endif
00040
00041 #include "MLV_event.h"
00042
00043 #ifdef __cplusplus
00044 extern "C" {
00045 #endif
00046
00051 typedef enum{
00052 MLV_BUTTON_LEFT = SDL_BUTTON_LEFT,
00053 MLV_BUTTON_MIDDLE = SDL_BUTTON_MIDDLE,
00054 MLV_BUTTON_RIGHT = SDL_BUTTON_RIGHT
00055 } MLV_Button;
00056
00068 void MLV_wait_mouse(int *x, int *y);
00069
00085 int MLV_wait_mouse_or_seconds(int *x, int *y, int seconds);
00086
00095 const char* MLV_convert_button_to_string( MLV_Button button_code );
00096
00103 MLV_Button MLV_convert_string_to_button( const char* button_string );
00104
00112 void MLV_get_mouse_position( int* x, int* y );
00113
00121 MLV_State MLV_get_mouse_button_state( MLV_Button mouse_button );
00122
00123 #ifdef __cplusplus
00124 }
00125 #endif
00126
00127 #endif