var hasTouch=function(){ var touchObj={}; touchObj.isSupportTouch = "ontouchend" in document ? true : false; touchObj.isEvent=touchObj.isSupportTouch?‘touchstart‘:‘click‘; return touchObj.isEvent; }
时间: 2024-11-10 10:21:14
var hasTouch=function(){ var touchObj={}; touchObj.isSupportTouch = "ontouchend" in document ? true : false; touchObj.isEvent=touchObj.isSupportTouch?‘touchstart‘:‘click‘; return touchObj.isEvent; }