Add event handlers.