public void fieldChanged()
        {
            if (dataGrid.SelectedRows.Count == 0)
            {
                return;
            }
            if (dataGrid.SelectedRows[0].Index == -1)
            {
                return;
            }
            if (dataIsChanging)
            {
                return;
            }
            dataIsChanging = true;
            MusicConfigEntry currEntry = MusicConfig.Entries[dataGrid.SelectedRows[0].Index];

            currEntry.szsNameInner = courseSelector.SelectedCourseNameEntry.szsName;
            currEntry.MusicName    = musicFileBox.Text;
            updateNameLabel();
            currEntry.MusicMode    = musicModeBox.Text;
            currEntry.NormalBPM    = bpmNormalBox.Text;
            currEntry.FastBPM      = bpmFastBox.Text;
            currEntry.NormalOffset = offsetNormalBox.Text;
            currEntry.FastOffset   = offsetFastBox.Text;
            dataGrid.DataSource    = MusicConfig.Entries;
            dataIsChanging         = false;
            dataGrid.Refresh();
        }
        public void rowChanged()
        {
            if (dataGrid.SelectedRows.Count == 0 || dataGrid.SelectedRows[0].Index == -1)
            {
                DisableInputs(true); return;
            }
            if (dataIsChanging)
            {
                return;
            }
            dataIsChanging = true;
            DisableInputs(false);
            MusicConfigEntry currEntry = MusicConfig.Entries[dataGrid.SelectedRows[0].Index];

            CTGP7CourseList.NameEntry entry = TranslateList.NameEntryFromSzsName(currEntry.szsNameInner);
            courseSelector.SelectedCourseNameEntry = entry;
            musicFileBox.Text = currEntry.MusicName;
            updateNameLabel();
            musicModeBox.Text    = currEntry.MusicMode;
            bpmNormalBox.Text    = currEntry.NormalBPM;
            bpmFastBox.Text      = currEntry.FastBPM;
            offsetNormalBox.Text = currEntry.NormalOffset;
            offsetFastBox.Text   = currEntry.FastOffset;
            dataGrid.DataSource  = MusicConfig.Entries;
            dataIsChanging       = false;
        }
        private void DeleteButton_Click(object sender, EventArgs e)
        {
            if (dataGrid.SelectedRows.Count == 0 || dataGrid.SelectedRows[0].Index == -1)
            {
                return;
            }
            MusicConfigEntry currEntry = MusicConfig.Entries[dataGrid.SelectedRows[0].Index];

            MusicConfig.Entries.Remove(currEntry);
            dataGrid.DataSource = null;
            dataGrid.DataSource = MusicConfig.Entries;
            DisableInputs(false);
        }