1
0
mirror of https://github.com/Pomax/BezierInfo-2.git synced 2025-09-28 00:59:00 +02:00
This commit is contained in:
Pomax
2020-08-08 13:29:56 -07:00
parent 975dcb1168
commit b85a87386b
2 changed files with 8 additions and 11 deletions

View File

@@ -93,12 +93,11 @@ class BaseAPI {
const left = evt.target.offsetLeft,
top = evt.target.offsetTop;
let x, y;
let x, y;
if (evt.targetTouches) {
const touch = evt.targetTouches;
for (let i=0; i<touch.length; i++) {
console.log(touch[i]);
if (!touch[i] || !touch[i].pageX) continue;
x = touch[i].pageX - left;
y = touch[i].pageY - top;