InputComponent: add a setting to disable SDL

In some situations it appears that the SDL code causes issues (such as
crashes), even if the user isn't using SDL. This new setting is supposed
to help debugging this. A user can set main.sdlEnabled to "false", and
we won't initialize and use SDL.
This commit is contained in:
Vincent Lang authored and LongChair committed 2018-02-07 20:35:44 +01:00
1 parent 6d10bfa1aa
commit fc3094567f
2 files changed
+6 -1

No files matched your search

+2 -1
View File
@@ -91,7 +91,8 @@ bool InputComponent::componentInitialize()
addInput(new InputAppleMediaKeys(this));
#endif
#ifdef HAVE_SDL
addInput(new InputSDL(this));
if (SettingsComponent::Get().value(SETTINGS_SECTION_MAIN, "sdlEnabled").toBool())
addInput(new InputSDL(this));
#endif
#ifdef HAVE_LIRC
addInput(new InputLIRC(this));