Esempio n. 1
0
        private void BtnEdit_Click(object sender, EventArgs e)
        {
            string selectedVar = null;

            if (CbxVariation != null && CbxVariation.SelectedItem != null)
            {
                selectedVar = CbxVariation.SelectedItem.ToString();
            }

            int selectedGrade     = CbxGrade.SelectedIndex;
            int selectedVariation = CbxVariation.SelectedIndex;

            CriteriaEditorV criteriaEditor = new CriteriaEditorV(presenter.CurShowedCriteria, CriteriaList, CriteriaIndex, selectedGrade, selectedVariation);

            criteriaEditor.ShowDialog();


            CbxGrade_SelectedIndexChanged(sender, e);

            if (selectedVar != null)
            {
                presenter.SelectVariationByReference(selectedVar);
            }

            Refresh();
        }
        private void BtnEditCriteria_Click(object sender, EventArgs e)
        {
            if (viewState == ViewState.IsRefreshing)
            {
                return;
            }
            int             criteriaIndex   = CriteriaList.IndexOf(presenter.SelectedCriteria);
            CriteriaEditorV criteriaEditorV = new CriteriaEditorV(presenter.SelectedCriteria, CriteriaList, criteriaIndex);

            criteriaEditorV.ShowDialog();
            RefreshView();
        }