Skip to content

Commit

Permalink
disable keep_open, fix no isCompleted #50
Browse files Browse the repository at this point in the history
will be enabled again when a better solution is found
  • Loading branch information
wang-bin committed Nov 16, 2023
1 parent fd35b8c commit 2299cf7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/src/video_player_mdk.dart
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ class MdkVideoPlayer extends mdk.Player {
_log.fine(
'$hashCode player$nativeHandle onPlaybackStateChanged: $oldValue => $newValue');
if (newValue == mdk.PlaybackState.stopped) {
// FIXME: keep_open no stopped
streamCtl.add(VideoEvent(eventType: VideoEventType.completed));
return;
}
Expand Down Expand Up @@ -195,7 +196,7 @@ class MdkVideoPlayerPlatform extends VideoPlayerPlatform {
final player = MdkVideoPlayer();
_log.fine('$hashCode player${player.nativeHandle} create($uri)');

player.setProperty("keep_open", "1");
//player.setProperty("keep_open", "1");
player.setProperty('avio.protocol_whitelist',
'file,rtmp,http,https,tls,rtp,tcp,udp,crypto,httpproxy,data,concatf,concat,subfile');
player.setProperty('avformat.rtsp_transport', 'tcp');
Expand Down

0 comments on commit 2299cf7

Please sign in to comment.