Fix some bugs associated with the single-page-app transition for event.