Пример #1
0
        protected override void OnCancel()
        {
            // should be in EditableObjectHelper...
            foreach (var b in blocksBeforeEdit)
            {
                if (!spec.IcdBlocks.Contains(b))
                {
                    spec.AddBlock(b);
                }
            }
            foreach (var b in spec.IcdBlocks)
            {
                if (!blocksBeforeEdit.Contains(b))
                {
                    spec.RemoveBlock(b);
                }
            }

            (spec as IEditableObject).CancelEdit();
        }