PanoramaWidget constructor

PanoramaWidget({
  1. Key? key,
  2. PlatformViewType platformViewType = PlatformViewType.Compat,
  3. TextDirection? textDirection,
  4. Set<Factory<OneSequenceGestureRecognizer>> gestureRecognizers = const <Factory<OneSequenceGestureRecognizer>>{},
  5. PlatformViewHitTestBehavior hitTestBehavior = PlatformViewHitTestBehavior.opaque,
  6. required void onPanoramaCreated(
    1. PanoramaPlayer
    ),
  7. double? scale,
})

Implementation

PanoramaWidget({
  super.key,
  super.platformViewType,
  super.textDirection,
  super.gestureRecognizers,
  super.hitTestBehavior,
  required this.onPanoramaCreated,
  this.scale,
}) : super(
        onViewCreated: (view) {
          final panorama = scale == null
              ? PlacesFactory.instance.createPanoramaPlayer(view)
              : PlacesFactory.instance
                  .createPanoramaPlayerWithScale(view, scaleFactor: scale);
          onPanoramaCreated(panorama);

          return true;
        },
      );