Emscripten: use UTF8ToString instead of Pointer_stringify
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39
diff --git a/src/SDL_assert.c b/src/SDL_assert.c
index ae763b2..35a45c1 100644
--- a/src/SDL_assert.c
+++ b/src/SDL_assert.c
@@ -250,7 +250,7 @@ SDL_PromptAssertion(const SDL_assert_data *data, void *userdata)
SDL_bool okay = SDL_TRUE;
char *buf = (char *) EM_ASM_INT({
var str =
- Pointer_stringify($0) + '\n\n' +
+ UTF8ToString($0) + '\n\n' +
'Abort/Retry/Ignore/AlwaysIgnore? [ariA] :';
var reply = window.prompt(str, "i");
if (reply === null) {
diff --git a/src/video/emscripten/SDL_emscriptenmouse.c b/src/video/emscripten/SDL_emscriptenmouse.c
index 1eadd0b..c7f2221 100644
--- a/src/video/emscripten/SDL_emscriptenmouse.c
+++ b/src/video/emscripten/SDL_emscriptenmouse.c
@@ -210,7 +210,7 @@ Emscripten_ShowCursor(SDL_Cursor* cursor)
if(curdata->system_cursor) {
EM_ASM_INT({
if (Module['canvas']) {
- Module['canvas'].style['cursor'] = Module['Pointer_stringify']($0);
+ Module['canvas'].style['cursor'] = UTF8ToString($0);
}
return 0;
}, curdata->system_cursor);
diff --git a/src/video/emscripten/SDL_emscriptenvideo.c b/src/video/emscripten/SDL_emscriptenvideo.c
index 9b2f775..cedafe3 100644
--- a/src/video/emscripten/SDL_emscriptenvideo.c
+++ b/src/video/emscripten/SDL_emscriptenvideo.c
@@ -344,7 +344,7 @@ static void
Emscripten_SetWindowTitle(_THIS, SDL_Window * window) {
EM_ASM_INT({
if (typeof Module['setWindowTitle'] !== 'undefined') {
- Module['setWindowTitle'](Module['Pointer_stringify']($0));
+ Module['setWindowTitle'](UTF8ToString($0));
}
return 0;
}, window->title);