Hi
I'm learning Javascript. I noticed that if I click on an object multiple times, quickly, some clicks are captured as double clicks. Is it possible to capture all clicks in Javascript as single clicks only?
Thanks
Hi
I'm learning Javascript. I noticed that if I click on an object multiple times, quickly, some clicks are captured as double clicks. Is it possible to capture all clicks in Javascript as single clicks only?
Thanks
Using jQuery, you could create a double click event handler on the document and then prevent that default behavior:
$(document).dblclick(function(e) {
e.preventDefault();
alert('Handler for .dblclick() called and ignored.');
});
Double click in the example to see the result.