微信长按出现菜单栏js代码

ios:

-webkit-user-select:none;
-ms-user-select: none;
-moz-user-select: none;
user-select: none;
-webkit-touch-callout:none;
-ms-touch-callout:none;
-mozt-touch-callout:none;
touch-callout:none;

安卓:
<div class="main3">touch事件</div>
$(function(){
$('.main3').bind('touchstart', function(e) {
if (e && e.preventDefault) {
e.preventDefault();
} else {
window.event.returnValue = false;
}
return false;
});
$('.main3').bind('touchmove', function(e) {
if (e && e.preventDefault) {
e.preventDefault();
} else {
window.event.returnValue = false;
}
return false;
});

$('.main3').bind('touchend', function(e) {
if (e && e.preventDefault) {
e.preventDefault();
} else {
window.event.returnValue = false;
}

})


})
原文地址:https://www.cnblogs.com/fcan/p/5228457.html