Clean-up ApplicationMain when running "display"