00001 #include "OSDLMouseCommon.h" 00002 00003 #include "SDL.h" // for SDL_BUTTON_* 00004 00005 00006 using std::string ; 00007 00008 using namespace OSDL::Events ; 00009 00010 00011 // Only one mouse managed for the moment : 00012 const MouseNumber OSDL::Events::DefaultMouse = 0 ; 00013 00014 00015 // The mapping between SDL button number and actual buttons : 00016 00017 const MouseButtonNumber OSDL::Events::LeftButton = SDL_BUTTON_LEFT ; 00018 const MouseButtonNumber OSDL::Events::MiddleButton = SDL_BUTTON_MIDDLE ; 00019 const MouseButtonNumber OSDL::Events::RightButton = SDL_BUTTON_RIGHT ; 00020 00021 const MouseButtonNumber OSDL::Events::WheelUp = SDL_BUTTON_WHEELUP ; 00022 const MouseButtonNumber OSDL::Events::WheelDown = SDL_BUTTON_WHEELDOWN ; 00023 00024 00025 00026 MouseException::MouseException( const std::string & reason ) throw() : 00027 EventsException( "Mouse exception : " + reason ) 00028 { 00029 00030 } 00031 00032 00033 MouseException::~MouseException() throw() 00034 { 00035 00036 } 00037