diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2014-12-31 12:56:42 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2014-12-31 12:56:42 +0300 |
commit | 784517dfb9650f284d5f7e283b47233c00183686 (patch) | |
tree | 312066c31bc790a78ce35df4e0b9c205517cfbea | |
parent | f3e7369d486670418db49241c0872d3d798c8fed (diff) |
Joystick: Suppress add/remove device events
Previously they'll be printed to the console as a totally unknown events
together claim this shouldn't have happened which is just misleading.
-rw-r--r-- | source/gameengine/GameLogic/Joystick/SCA_JoystickEvents.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source/gameengine/GameLogic/Joystick/SCA_JoystickEvents.cpp b/source/gameengine/GameLogic/Joystick/SCA_JoystickEvents.cpp index 08f4d97ed1b..0033c137eb6 100644 --- a/source/gameengine/GameLogic/Joystick/SCA_JoystickEvents.cpp +++ b/source/gameengine/GameLogic/Joystick/SCA_JoystickEvents.cpp @@ -124,6 +124,12 @@ void SCA_Joystick::HandleEvents(void) SCA_Joystick::m_instance[sdl_event.jball.which]->OnBallMotion(&sdl_event); break; #endif +#if SDL_VERSION_ATLEAST(2, 0, 0) + case SDL_JOYDEVICEADDED: + case SDL_JOYDEVICEREMOVED: + /* pass */ + break; +#endif default: printf("SCA_Joystick::HandleEvents, Unknown SDL event (%d), this should not happen\n", sdl_event.type); break; |