示例#1
0
 protected override PointD ConstrainNewLocation(IInputModeContext context, PointD originalLocation, PointD newLocation)
 {
     return(newLocation.GetConstrained(node.Layout.ToRectD()));
 }
 /// <summary>
 /// Returns the position that is constrained by the rectangle.
 /// </summary>
 protected override PointD ConstrainNewLocation(IInputModeContext context, PointD originalLocation,
                                                PointD newLocation)
 {
     return(newLocation.GetConstrained(boundaryPositionRectangle));
 }