canvas windows 平板模式获取鼠标位置
//判断是否是平板
function IsTouchEnabled() {
return ( 'ontouchstart' in window ) ||
( navigator.maxTouchPoints > 0 ) ||
( navigator.msMaxTouchPoints > 0 )
}
@touchstart
@touchmove
const isPad = IsTouchEnabled()
const rect = .
原创
2022-04-19 17:32:34 ·
190 阅读 ·
0 评论