Skip to content

Commit

Permalink
[HTML5] Properly set canvas size during setup.
Browse files Browse the repository at this point in the history
It used to be updated before the first iteration, causing the
window/viewport size values to be incorrect during the initialization
phase (e.g. during the first `_ready` notification).
  • Loading branch information
Faless committed Mar 9, 2021
1 parent 0bef220 commit 3f059b9
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions platform/javascript/js/libs/library_godot_display.js
Original file line number Diff line number Diff line change
Expand Up @@ -805,6 +805,7 @@ const GodotDisplay = {
canvas.style.left = 0;
break;
}
GodotDisplayScreen.updateSize();
if (p_fullscreen) {
GodotDisplayScreen.requestFullscreen();
}
Expand Down

0 comments on commit 3f059b9

Please sign in to comment.