コード例 #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="FocusReplaceWithCycleOperation"/> class.
 /// </summary>
 /// <param name="parentNode">Node where the replacement is taking place.</param>
 /// <param name="propertyName">Property of <paramref name="parentNode"/> where the node is replaced.</param>
 /// <param name="blockIndex">Block position where the node is replaced, if applicable.</param>
 /// <param name="index">Position where the node is replaced, if applicable.</param>
 /// <param name="cycleIndexList">Cycle of nodes that can replace the current node.</param>
 /// <param name="cyclePosition">New position in the cycle.</param>
 /// <param name="handlerRedo">Handler to execute to redo the operation.</param>
 /// <param name="handlerUndo">Handler to execute to undo the operation.</param>
 /// <param name="isNested">True if the operation is nested within another more general one.</param>
 public FocusReplaceWithCycleOperation(Node parentNode, string propertyName, int blockIndex, int index, FocusInsertionChildNodeIndexList cycleIndexList, int cyclePosition, System.Action <IWriteableOperation> handlerRedo, System.Action <IWriteableOperation> handlerUndo, bool isNested)
     : base(parentNode, propertyName, blockIndex, index, clearNode: false, cycleIndexList[cyclePosition].Node, handlerRedo, handlerUndo, isNested)
 {
     CycleIndexList   = cycleIndexList;
     NewCyclePosition = cyclePosition;
 }
コード例 #2
0
 /// <summary>
 /// Creates a IxxxReplaceOperation object.
 /// </summary>
 private protected virtual IFocusReplaceWithCycleOperation CreateReplaceWithCycleOperation(int blockIndex, int index, FocusInsertionChildNodeIndexList cycleIndexList, int cyclePosition, System.Action <IWriteableOperation> handlerRedo, System.Action <IWriteableOperation> handlerUndo, bool isNested)
 {
     ControllerTools.AssertNoOverride(this, Type.FromTypeof <FocusReplaceWithCycleOperation>());
     return(new FocusReplaceWithCycleOperation(ParentNode, PropertyName, blockIndex, index, cycleIndexList, cyclePosition, handlerRedo, handlerUndo, isNested));
 }