ArcballControls constructor

ArcballControls(
  1. dynamic camera,
  2. dynamic listenableKey, [
  3. dynamic scene,
  4. dynamic devicePixelRatio = 1.0,
])

Implementation

ArcballControls(camera, listenableKey, [scene, devicePixelRatio = 1.0]) : super() {
  _state = State2.idle;

  setCamera(camera);

  if (scene != null) {
    scene!.add(_gizmos);
  }

  // domElement.style.touchAction = 'none';
  _devPxRatio = devicePixelRatio;

  initializeMouseActions();

  domElement.addEventListener('contextmenu', onContextMenu);
  domElement.addEventListener('wheel', onWheel);
  domElement.addEventListener('pointerdown', onPointerDown);
  domElement.addEventListener('pointercancel', onPointerCancel);

  // window.addEventListener( 'resize', onWindowResize );
}