[client][EventsView] Form a function to setup event callbacks.