draws line on mouse click