/**
   * The mouse location changed during a drag, while this MapTool was the active one.
   *
   * @param point The location of the mouse in world coordinates.
   * @param evt The original event.
   */
  public void updateDrag(Point2D.Double point, MouseEvent evt) {
    // just in case we didn't get a mousePressed-Event
    if (dragStartPos == null) {
      dragStartPos = (Point2D.Double) point.clone();
      setMeasureCursor();
      return;
    }

    // if this is the first time mouseDragged is called, capture the screen.
    if (dragCurrentPos == null) captureBackground();

    dragCurrentPos = (Point2D.Double) point.clone();
    mapComponent.repaint();

    reportDistance(false);
  }
 /**
  * The mouse starts a drag, while this MapTool was the active one.
  *
  * @param point The location of the mouse in world coordinates.
  * @param evt The original event.
  */
 public void startDrag(Point2D.Double point, MouseEvent evt) {
   setMeasureCursor();
   this.dragStartPos = (Point2D.Double) point.clone();
 }