onDoublePanStart method

void onDoublePanStart()

Implementation

void onDoublePanStart() {
  if (enabled && enablePan) {
    dispatchEvent(_startEvent);

    updateTbState(State2.pan, true);

    setCenter(
        (_touchCurrent[0].clientX + _touchCurrent[1].clientX) / 2,
        (_touchCurrent[0].clientY + _touchCurrent[1].clientY) / 2);
    _startCursorPosition.setFrom(
      unprojectOnTbPlane(
        camera, _center.x, _center.y, true
      )
    );
    _currentCursorPosition.setFrom(_startCursorPosition);

    activateGizmos(false);
  }
}