Added a check for SDL_QUIT events in BOSystem