Cleaned source code and improved performance with mousemove event.