// Returns true if an AdditionalSnapLine can be found in a close surrounding of the given location.
        private bool IsValidHit(IInputModeContext context, PointD location)
        {
            AdditionalSnapLineVisualCreator line = TryGetAdditionalSnapLineAt(location);

            if (line != null)
            {
                handler = new AdditionalSnapLinePositionHandler(line, location);
                return(true);
            }
            handler = null;
            return(false);
        }
 /// <summary>
 /// Creates a new handler for the given <paramref name="line">AdditionalSnapLine</paramref>.
 /// </summary>
 /// <param name="line">The additional snap line to move.</param>
 /// <param name="mouseLocation">The mouse location at the beginning of a move gesture.</param>
 public AdditionalSnapLinePositionHandler(AdditionalSnapLineVisualCreator line, PointD mouseLocation)
 {
     this.line           = line;
     mouseDeltaFromStart = mouseLocation - line.From;
 }