public PlayDefinitionWindow()
        {
            InitializeComponent();

            PutPlayToControls(null);

            InitializeCommandsList();
            InitializeComboBoxes();

            PlayGroup      playsList = new PlayGroup();
            AutonomousPlay newPlay   = new AutonomousPlay("new");

            newPlay.L_LL[0] = "L_LL";
            newPlay.L_LR[0] = "L_LR";
            newPlay.L_RR[0] = "L_RR";
            newPlay.L_RL[0] = "L_RL";

            newPlay.C_LL[0] = "C_LL";
            newPlay.C_LR[0] = "C_LR";
            newPlay.C_RR[0] = "C_RR";
            newPlay.C_RL[0] = "C_RL";

            newPlay.R_LL[0] = "R_LL";
            newPlay.R_LR[0] = "R_LR";
            newPlay.R_RR[0] = "R_RR";
            newPlay.R_RL[0] = "R_RL";

            playsList.AutonomousPlays.Add(newPlay);
            AddNewRoute(playsList);
        }
        /// <summary>
        /// Save the current data to the specified file.
        /// </summary>
        ///
        /// <param name="filename">The name and path of the file to save to</param>
        ///
        private void SaveFile(String filename)
        {
            PlayGroup playList = mPlays;

            if (playList != null)
            {
                playList.Save(filename);
                SaveFilename = filename;
            }
        }
        private void SaveButton_Click(object sender, RoutedEventArgs e)
        {
            PlayGroup playList = mPlays;

            if (playList != null)
            {
                if (String.IsNullOrEmpty(SaveFilename))
                {
                    SaveAsButton_Click(sender, e);
                }
                else
                {
                    SaveFile(SaveFilename);
                }
            }
        }
 private void AddNewPlay(Autonomous_x.PlayGroup playsList)
 {
     mPlays = playsList;
     UpdatePlayList();
     PlaysLB.SelectedIndex = 0;
 }
 private void AddNewRoute(Autonomous_x.PlayGroup playsList)
 {
     mPlays = playsList;
     UpdatePlayList();
     //ProgramModeLB.SelectedIndex = 0;
 }