Fix mouse detection

This commit is contained in:
2024-04-14 23:50:00 +02:00
parent 4801f78deb
commit 4b6275d2e0
3 changed files with 11 additions and 7 deletions

View File

@ -1,11 +1,5 @@
import { Editor } from "../main";
// mouse.ts
export const onmousemove = (app: Editor) => (e: MouseEvent): void => {
app._mouseX = e.pageX;
app._mouseY = e.pageY;
};
export const mouseX = (app: Editor) => (): number => {
/**
* @returns The current x position of the mouse