693Changing the Cursor with Events when dragging an HTML5 canvas

With jQuery document ready:

$(function(){
    var canvas = $('#testCanvas')[0];
    canvas.addEventListener('mousedown', function(e){
        e.preventDefault();
        e.stopPropagation();
        e.target.style.cursor = 'move';
    }, false);
    canvas.addEventListener('mouseup', function(e){
        e.target.style.cursor = 'default';
    }, false);
});

And without...

$('#testCanvas')[0].addEventListener('mousedown', function(e){
    e.preventDefault();
    e.stopPropagation();
    e.target.style.cursor = 'move';
}, false);

$('#testCanvas')[0].addEventListener('mouseup', function(e) {
    e.target.style.cursor = 'default';
}, false);

Based on this: http://stackoverflow.com/questions/2659999/html5-canvas-hand-cursor-problems