click event for lock