Browse Source

🐛 Only initialize the subsystems that we use

Fixes #1391

For now this stops the initalization of sensor subsystem, but in the
future SDL may add more that we do not care about.
pull/1485/head
Anders Jenbo 5 years ago
parent
commit
0cc788b33d
  1. 6
      SourceX/display.cpp

6
SourceX/display.cpp

@ -125,9 +125,9 @@ bool SpawnWindow(const char *lpWindowName)
SDL_SetHint(SDL_HINT_TOUCH_MOUSE_EVENTS, "0");
#endif
int initFlags = SDL_INIT_EVERYTHING & ~SDL_INIT_HAPTIC;
#ifdef __3DS__
initFlags = SDL_INIT_TIMER | SDL_INIT_VIDEO | SDL_INIT_JOYSTICK;
int initFlags = SDL_INIT_AUDIO | SDL_INIT_VIDEO | SDL_INIT_JOYSTICK;
#ifndef USE_SDL1
initFlags |= SDL_INIT_GAMECONTROLLER;
#endif
if (SDL_Init(initFlags) <= -1) {
ErrSdl();

Loading…
Cancel
Save