Skip to content
This repository was archived by the owner on Feb 22, 2023. It is now read-only.

Commit 46207ea

Browse files
[video_player]: Fix texture unregistration callback signature
Flutter's video plugin can cause crashes after a closing a flutter view on simulator model iPhone X or higher Co-authored-by: Mike Diarmid <mike.diarmid@gmail.com>
1 parent bb21db8 commit 46207ea

File tree

3 files changed

+6
-2
lines changed

3 files changed

+6
-2
lines changed

packages/video_player/video_player/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
## 2.0.0-nullsafety.9
2+
3+
* Fixed an issue where a crash can occur after a closing a video player view on iOS.
4+
15
## 2.0.0-nullsafety.8
26

37
* Migrated from deprecated `defaultBinaryMessenger`.

packages/video_player/video_player/ios/Classes/FLTVideoPlayerPlugin.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -392,7 +392,7 @@ - (CVPixelBufferRef)copyPixelBuffer {
392392
}
393393
}
394394

395-
- (void)onTextureUnregistered {
395+
- (void)onTextureUnregistered:(NSObject<FlutterTexture>*)texture {
396396
dispatch_async(dispatch_get_main_queue(), ^{
397397
[self dispose];
398398
});

packages/video_player/video_player/pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ description: Flutter plugin for displaying inline video with other Flutter
44
# 0.10.y+z is compatible with 1.0.0, if you land a breaking change bump
55
# the version to 2.0.0.
66
# See more details: https://github.com/flutter/flutter/wiki/Package-migration-to-1.0.0
7-
version: 2.0.0-nullsafety.8
7+
version: 2.0.0-nullsafety.9
88
homepage: https://github.com/flutter/plugins/tree/master/packages/video_player/video_player
99

1010
flutter:

0 commit comments

Comments
 (0)