コード例 #1
0
 public void DuplicateObject()
 {
     if (_currentCslaObject != null)
     {
         _currentUnit.CslaObjects.Add(_currentCslaObject.Duplicate(_schema));
         _currentCslaObject = _currentUnit.CslaObjects[_currentUnit.CslaObjects.Count - 1];
         _currentCslaObject.ObjectNameChanged += new EventHandler(CslaObject_ObjectNameChanged);
         frmGenerator.CslaObjectList.Items.Add(new DictionaryEntry(_currentCslaObject.ObjectName, _currentCslaObject));
         frmGenerator.CslaObjectList.SelectedIndex = frmGenerator.CslaObjectList.Items.Count - 1;
     }
 }