Move main menu impl into its own file.