view.addEventListener('touchend', (e) => {
let x = e.screenX
let y = e.screenY
let halfWidth = windowWidth / 2
let popupStyle = {
top: y + "px",
width: "50px",
height: "50px"
}
if (x < halfWidth ) {
popupStyle.left = '0px'
} else {
popupStyle.left = (windowWidth - 50) + 'px'
}
view.setStyle(popupStyle)
})
这个touchend 经常不会被回调,这个怎么回事
0 个回复