Move mouseLocs track code outside from init

If init function called a lot of times, the browser dramatically slow
down, because the mouse location track function called every time of
mouse move * init function call count.