summaryrefslogtreecommitdiff
path: root/platform/web
diff options
context:
space:
mode:
authorFabio Alessandrelli <fabio.alessandrelli@gmail.com>2022-10-08 12:31:08 +0200
committerGitHub <noreply@github.com>2022-10-08 12:31:08 +0200
commitb150926cde1683667d3e725b2928a7a28765df0f (patch)
tree03dd54780ae26f528280ff9360104a1d20a16b31 /platform/web
parent18177828ad97286ca88cbdcfb763c967858d051b (diff)
parentc2d7f7fb4ccb62c9a1130405b7da97626e19b3d9 (diff)
Merge pull request #67045 from winterpixelgames/bugfix-web-cursor
Fix bug in setting custom cursor on web
Diffstat (limited to 'platform/web')
-rw-r--r--platform/web/js/libs/library_godot_display.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/platform/web/js/libs/library_godot_display.js b/platform/web/js/libs/library_godot_display.js
index 91cb8e728a..39c8569655 100644
--- a/platform/web/js/libs/library_godot_display.js
+++ b/platform/web/js/libs/library_godot_display.js
@@ -174,7 +174,7 @@ const GodotDisplayCursor = {
$GodotDisplayCursor__deps: ['$GodotOS', '$GodotConfig'],
$GodotDisplayCursor__postset: 'GodotOS.atexit(function(resolve, reject) { GodotDisplayCursor.clear(); resolve(); });',
$GodotDisplayCursor: {
- shape: 'auto',
+ shape: 'default',
visible: true,
cursors: {},
set_style: function (style) {
@@ -185,7 +185,7 @@ const GodotDisplayCursor = {
let css = shape;
if (shape in GodotDisplayCursor.cursors) {
const c = GodotDisplayCursor.cursors[shape];
- css = `url("${c.url}") ${c.x} ${c.y}, auto`;
+ css = `url("${c.url}") ${c.x} ${c.y}, default`;
}
if (GodotDisplayCursor.visible) {
GodotDisplayCursor.set_style(css);
@@ -193,7 +193,7 @@ const GodotDisplayCursor = {
},
clear: function () {
GodotDisplayCursor.set_style('');
- GodotDisplayCursor.shape = 'auto';
+ GodotDisplayCursor.shape = 'default';
GodotDisplayCursor.visible = true;
Object.keys(GodotDisplayCursor.cursors).forEach(function (key) {
URL.revokeObjectURL(GodotDisplayCursor.cursors[key]);