Cleaning up MainWindow