Cleaning up adding event listeners.