emscripten: Fixed not removing pointer lock event callback.
authorPhilipp Wiesemann <philipp.wiesemann@arcor.de>
Sat, 13 May 2017 23:00:35 +0200
changeset 11003ced20e690a19
parent 11002 ba0ce5b958d2
child 11004 898888ce469a
emscripten: Fixed not removing pointer lock event callback.
src/video/emscripten/SDL_emscriptenevents.c
     1.1 --- a/src/video/emscripten/SDL_emscriptenevents.c	Fri May 12 23:01:17 2017 +0200
     1.2 +++ b/src/video/emscripten/SDL_emscriptenevents.c	Sat May 13 23:00:35 2017 +0200
     1.3 @@ -676,6 +676,8 @@
     1.4      emscripten_set_touchmove_callback("#canvas", NULL, 0, NULL);
     1.5      emscripten_set_touchcancel_callback("#canvas", NULL, 0, NULL);
     1.6  
     1.7 +    emscripten_set_pointerlockchange_callback(NULL, NULL, 0, NULL);
     1.8 +
     1.9      const char *target = SDL_GetHint(SDL_HINT_EMSCRIPTEN_KEYBOARD_ELEMENT);
    1.10      if (!target) {
    1.11          target = "#window";
    1.12 @@ -683,7 +685,6 @@
    1.13  
    1.14      emscripten_set_keydown_callback(target, NULL, 0, NULL);
    1.15      emscripten_set_keyup_callback(target, NULL, 0, NULL);
    1.16 -
    1.17      emscripten_set_keypress_callback(target, NULL, 0, NULL);
    1.18  
    1.19      emscripten_set_fullscreenchange_callback("#document", NULL, 0, NULL);