mousedown and touchstart events now always call preventDefault

This commit is contained in:
Eric Rowell
2013-05-31 23:04:07 -07:00
parent 3cfd49a03e
commit 324d841ed4
3 changed files with 28 additions and 1 deletions

View File

@@ -38,6 +38,13 @@
this.element.style.background = 'transparent';
this.context = this.element.getContext(contextType);
this.setSize(width, height);
this.element.addEventListener('mousedown', function(evt) {
evt.preventDefault();
});
this.element.addEventListener('touchstart', function(evt) {
evt.preventDefault();
});
},
/**
* get canvas element