fix: black screen with external subtitles

This commit is contained in:
edde746
2026-01-11 12:59:25 +01:00
parent a91a419ef3
commit cffef8671e
2 changed files with 62 additions and 46 deletions
+5 -1
View File
@@ -424,10 +424,14 @@ class PlayerNative implements Player {
await setProperty('start', 'none');
}
await command(['loadfile', media.uri, 'replace']);
// Set pause BEFORE loadfile to prevent decoder from starting immediately.
// This is important for adding external subtitles before playback begins,
// avoiding a race condition that can freeze the video decoder on Android (issue #226).
if (!play) {
await setProperty('pause', 'yes');
}
await command(['loadfile', media.uri, 'replace']);
}
@override