Uncategorized

Check sự kiện click hoặc move element bằng jquery

var isMove = false;
$(element )
.mousedown(function() {
    isMove= false;
})
.mousemove(function() {
    isMove = true;
 })
.mouseup(function() {
    if(isMove){
       alert('click element');
    }else{
       alert('di chuyen element');
    }
});

Leave a Reply

Your email address will not be published. Required fields are marked *