Added some code for mouse
Added some code for touches