mirror of https://github.com/encounter/SDL.git
Emscripten: resize canvas to 0x0 in DestroyWindow
Closest we can get to actually destroying it
This commit is contained in:
parent
d60546aaa8
commit
04b1494cf8
|
@ -293,6 +293,10 @@ Emscripten_DestroyWindow(_THIS, SDL_Window * window)
|
||||||
data->egl_surface = EGL_NO_SURFACE;
|
data->egl_surface = EGL_NO_SURFACE;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/* We can't destroy the canvas, so resize it to zero instead */
|
||||||
|
emscripten_set_canvas_element_size(NULL, 0, 0);
|
||||||
|
|
||||||
SDL_free(window->driverdata);
|
SDL_free(window->driverdata);
|
||||||
window->driverdata = NULL;
|
window->driverdata = NULL;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue