Skip to content

Commit da938aa

Browse files
authored
Remove references to non-existant SDL.mouseX/Y. NFC (#21655)
SDL.mouseX and SDL.mouseY were removed back in 48456b5.
1 parent af763a9 commit da938aa

File tree

1 file changed

+3
-10
lines changed

1 file changed

+3
-10
lines changed

src/library_browser.js

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -593,16 +593,9 @@ var LibraryBrowser = {
593593
Browser.mouseMovementY = Browser.getMovementY(event);
594594
}
595595

596-
// check if SDL is available
597-
if (typeof SDL != "undefined") {
598-
Browser.mouseX = SDL.mouseX + Browser.mouseMovementX;
599-
Browser.mouseY = SDL.mouseY + Browser.mouseMovementY;
600-
} else {
601-
// just add the mouse delta to the current absolute mouse position
602-
// FIXME: ideally this should be clamped against the canvas size and zero
603-
Browser.mouseX += Browser.mouseMovementX;
604-
Browser.mouseY += Browser.mouseMovementY;
605-
}
596+
// add the mouse delta to the current absolute mouse position
597+
Browser.mouseX += Browser.mouseMovementX;
598+
Browser.mouseY += Browser.mouseMovementY;
606599
} else {
607600
if (event.type === 'touchstart' || event.type === 'touchend' || event.type === 'touchmove') {
608601
var touch = event.touch;

0 commit comments

Comments
 (0)