added on click event to controls