I am developing a cordova app. Because of the 300ms delay with the click event I don't want to use that. How do I change the event a <input type='checkbox'>
element listens to for toggeling it's checkmark from click
to e.g. touchstart
?
The closest I got was making the checkbox disabled
and adding this code:
$(':checkbox').each(function(){
$(this).bind('touchstart', function(){
if(this.checked) {
this.checked = true;
} else {
this.checked = false;
}
})
});
Unfortunately touchstart does not trigger.