diff --git a/lib/widgets/viewer/visual/video/swipe_action.dart b/lib/widgets/viewer/visual/video/swipe_action.dart index 7a7e287cb..da3a6b153 100644 --- a/lib/widgets/viewer/visual/video/swipe_action.dart +++ b/lib/widgets/viewer/visual/video/swipe_action.dart @@ -14,7 +14,7 @@ extension ExtraSwipeAction on SwipeAction { case SwipeAction.brightness: return AvesApp.screenBrightness?.application ?? Future.value(1); case SwipeAction.volume: - return VolumeController().getVolume(); + return VolumeController.instance.getVolume(); } } @@ -23,7 +23,8 @@ extension ExtraSwipeAction on SwipeAction { case SwipeAction.brightness: await AvesApp.screenBrightness?.setApplicationScreenBrightness(value); case SwipeAction.volume: - VolumeController().setVolume(value, showSystemUI: false); + VolumeController.instance.showSystemUI = false; + await VolumeController.instance.setVolume(value); } } } diff --git a/pubspec.lock b/pubspec.lock index dce86a470..60fa935d0 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -791,8 +791,8 @@ packages: dependency: "direct overridden" description: path: media_kit - ref: "4d8c634c28d439384aab40b9d2edff83077f37c9" - resolved-ref: "4d8c634c28d439384aab40b9d2edff83077f37c9" + ref: d2145a50f68394096845915a28874341fbf5b3fe + resolved-ref: d2145a50f68394096845915a28874341fbf5b3fe url: "https://github.com/media-kit/media-kit.git" source: git version: "1.1.11" @@ -808,8 +808,8 @@ packages: dependency: "direct overridden" description: path: media_kit_video - ref: "4d8c634c28d439384aab40b9d2edff83077f37c9" - resolved-ref: "4d8c634c28d439384aab40b9d2edff83077f37c9" + ref: d2145a50f68394096845915a28874341fbf5b3fe + resolved-ref: d2145a50f68394096845915a28874341fbf5b3fe url: "https://github.com/media-kit/media-kit.git" source: git version: "1.2.5" @@ -1673,10 +1673,10 @@ packages: dependency: "direct main" description: name: volume_controller - sha256: c71d4c62631305df63b72da79089e078af2659649301807fa746088f365cb48e + sha256: "30863a51338db47fe16f92902b1a6c4ee5e15c9287b46573d7c2eb6be1f197d2" url: "https://pub.dev" source: hosted - version: "2.0.8" + version: "3.3.1" wakelock_plus: dependency: transitive description: diff --git a/pubspec.yaml b/pubspec.yaml index 0799282f2..aae56878e 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -134,12 +134,12 @@ dependency_overrides: media_kit: git: url: https://github.com/media-kit/media-kit.git - ref: 4d8c634c28d439384aab40b9d2edff83077f37c9 + ref: d2145a50f68394096845915a28874341fbf5b3fe path: media_kit media_kit_video: git: url: https://github.com/media-kit/media-kit.git - ref: 4d8c634c28d439384aab40b9d2edff83077f37c9 + ref: d2145a50f68394096845915a28874341fbf5b3fe path: media_kit_video dev_dependencies: