Add EventListener to MainWindow.