Set hint regardless of setting (in case it is changed during run-time).

This commit is contained in:
Aloshi 2015-01-15 17:47:31 -06:00
parent da42b784b2
commit 2926442bf0

View file

@ -46,9 +46,8 @@ void InputManager::init()
if(initialized())
deinit();
if (Settings::getInstance()->getBool("BackgroundJoystickInput")){
SDL_SetHint(SDL_HINT_JOYSTICK_ALLOW_BACKGROUND_EVENTS, "1");
}
SDL_SetHint(SDL_HINT_JOYSTICK_ALLOW_BACKGROUND_EVENTS,
Settings::getInstance()->getBool("BackgroundJoystickInput") ? "1" : "0");
SDL_InitSubSystem(SDL_INIT_JOYSTICK);
SDL_JoystickEventState(SDL_ENABLE);