<div
class="reply-item"
@touchstart="touchStart(item, $event)"
@touchmove="touchMove()"
@touchend="touchEnd()" >
</div>
touchStart(item, event) {
var that = this;
// event.preventDefault(); 取消复制
clearTimeout(this.Loop); //再次清空定时器,防止重复注册定时器
this.Loop = setTimeout(
function() {
that.Loop = 0;
this.show_cell = true;
this.item_id = item;
}.bind(this),
500
);
return false;
},
touchMove(event) {
clearTimeout(this.Loop); //清除定时器
this.Loop = 0;
},
touchEnd(event) {
var that = this;
clearTimeout(this.Loop); //清空定时器,防止重复注册定时器
if (that.Loop != 0) {
// this.show_cell = true
}
return false;
},
css取消复制
-webkit-touch-callout:none; -webkit-user-select:none;
-khtml-user-select:none; -moz-user-select:none;
-ms-user-select:none;user-select:none;