From b8ed8b2cd0718586786828f1580f491798051235 Mon Sep 17 00:00:00 2001 From: Alesia Date: Tue, 29 Aug 2023 15:44:25 +0300 Subject: [PATCH] fix gyroscope issue --- .../kotlin/wtf/flutter/vr_player/VideoPlayerController.kt | 4 +--- example/lib/main.dart | 3 +-- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/android/src/main/kotlin/wtf/flutter/vr_player/VideoPlayerController.kt b/android/src/main/kotlin/wtf/flutter/vr_player/VideoPlayerController.kt index 075a2f4..7696507 100644 --- a/android/src/main/kotlin/wtf/flutter/vr_player/VideoPlayerController.kt +++ b/android/src/main/kotlin/wtf/flutter/vr_player/VideoPlayerController.kt @@ -317,9 +317,7 @@ class VideoPlayerController( val vrSettings = VRSettings() vrSettings.isFlingEnabled = true vrSettings.isVrModeEnabled = false - - if (isVRModeEnabled) vrSettings.interactionMode = VRInteractionMode.MotionWithTouch - else vrSettings.interactionMode = VRInteractionMode.Touch + vrSettings.interactionMode = VRInteractionMode.MotionWithTouch vrSettings.isZoomWithPinchEnabled = true return vrSettings diff --git a/example/lib/main.dart b/example/lib/main.dart index 6c91e3a..80ae577 100644 --- a/example/lib/main.dart +++ b/example/lib/main.dart @@ -163,8 +163,7 @@ class _VideoPlayerPageState extends State thumbShape: const RoundSliderThumbShape( enabledThumbRadius: 8, ), - overlayColor: - Colors.purple.withAlpha(32), + overlayColor: Colors.purple.withAlpha(32), overlayShape: const RoundSliderOverlayShape( overlayRadius: 14, ),