Hide Mouse Cursor when it's within HTML5 Canvas Javascript

Viewed 24215

I'm in the process of making a game using Javascript and the html5 canvas element as an alternative to Flash. My question is: is there any bit of code I can use to hide the mouse cursor/pointer as it passes within the canvas? Help is much appreciated!

4 Answers

Select the canvas element:

 canvas = document.getElementById("canvas");

Get context :

context = canvas.getContext("2d");

Set none :

context.strokeStyle = none; 
Related