public void AddPoseCombination(Mode mode, PoseCombination poseCombination, bool isEdit, int editIndex)
 {
     if (isEdit)
     {
         mode.RemovePoseCombinationByIndex(editIndex);
         mode.InsertPoseCombination(editIndex, poseCombination);
     }
     else
         mode.AddPoseCombination(poseCombination);
 }
        public void ProcessPoseCombinationGridViewCell(Mode mode, int rowIndex, int columnIndex, PresentationModel presentationModel)
        {
            if (rowIndex >= 0)
            {
                PoseCombinationSelect poseCombinationForm = new PoseCombinationSelect(presentationModel, mode, rowIndex);
                switch (columnIndex)
                {
                    // this is delete button, we add delete columns first, then format binding columns
                    // so delete button columns index while be 0, even we setting displayIndex is 1
                    case 0:
                        mode.RemovePoseCombinationByIndex(rowIndex);
                        break;

                    case 2:
                        mode.GetPoseCombination(rowIndex).IsEnable = !mode.GetPoseCombination(rowIndex).IsEnable;
                        break;

                    default:
                        poseCombinationForm.ShowDialog();
                        break;
                }
            }
        }