Update to click method
Add update thread, fix click on mouse stop, remove main method