Skip to content

gamecontroller: Do SDL_Init later

Jeremy Whiting requested to merge work/whiting/sdlinitlater into master

Includes other commit to poll less when we can, but adds running SDL_Init from poll() when not initialized yet. Note the initialized = false; in the destructor is needed for when we run from systemsettings, so when we unload then load the kcm again we rerun SDL_Init. Otherwise we don't detect anything on the second run.

Fixes 482696 but a better solution can be next moving all SDL operations into a separate thread.

CC @redstrate

Signed-off-by: Jeremy Whiting jpwhiting@kde.org

Merge request reports