summaryrefslogtreecommitdiff
path: root/platform/javascript/display_server_javascript.cpp
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2021-02-11 10:53:22 +0100
committerGitHub <noreply@github.com>2021-02-11 10:53:22 +0100
commit5d5ed2717385b2dd646b8f4060147f662637e229 (patch)
tree54b9ed59bffc96bf32fe78f2ef522a008c630957 /platform/javascript/display_server_javascript.cpp
parentad293a82f1fc2e4baa35f54b9b8038df72d23737 (diff)
parent3366122e1aecf46c668e47d8c40041b53d247dc0 (diff)
Merge pull request #45883 from Faless/js/4.x_more_handlers
[HTML5] Handle contextmenu, webglcontextlost internally.
Diffstat (limited to 'platform/javascript/display_server_javascript.cpp')
-rw-r--r--platform/javascript/display_server_javascript.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/platform/javascript/display_server_javascript.cpp b/platform/javascript/display_server_javascript.cpp
index cfe093693f..b54ac5230a 100644
--- a/platform/javascript/display_server_javascript.cpp
+++ b/platform/javascript/display_server_javascript.cpp
@@ -703,6 +703,9 @@ DisplayServerJavaScript::DisplayServerJavaScript(const String &p_rendering_drive
// Ensure the canvas ID.
godot_js_config_canvas_id_get(canvas_id, 256);
+ // Handle contextmenu, webglcontextlost
+ godot_js_display_setup_canvas();
+
// Check if it's windows.
swap_cancel_ok = godot_js_display_is_swap_ok_cancel() == 1;