JS optimizations.

- For in loops for arrays are now regular for loops.
- Mousemove event listener only listening to canvas element instead of window.