From 7a1f76ee85fc5a041fe4ebab3430d3e9f5533db7 Mon Sep 17 00:00:00 2001 From: Flummi Date: Sun, 22 Jun 2025 03:40:13 +0200 Subject: [PATCH] v1.4.5+66 --- lib/widgets/video_widget.dart | 7 +++++++ pubspec.yaml | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/lib/widgets/video_widget.dart b/lib/widgets/video_widget.dart index 507899d..0650a15 100644 --- a/lib/widgets/video_widget.dart +++ b/lib/widgets/video_widget.dart @@ -85,6 +85,13 @@ class _VideoWidgetState extends State { @override void didUpdateWidget(covariant VideoWidget oldWidget) { super.didUpdateWidget(oldWidget); + + if (widget.details.mediaUrl != oldWidget.details.mediaUrl) { + videoController.dispose(); + _initController(); + return; + } + if (widget.isActive != oldWidget.isActive) { if (widget.isActive) { videoController.play(); diff --git a/pubspec.yaml b/pubspec.yaml index 479fa2a..4e57f2a 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -16,7 +16,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html # In Windows, build-name is used as the major, minor, and patch parts # of the product and file versions while build-number is used as the build suffix. -version: 1.4.4+65 +version: 1.4.5+66 environment: sdk: ^3.9.0-100.2.beta