mod: 代码优化

This commit is contained in:
orz12
2024-03-01 15:55:59 +08:00
parent ba64a80bc7
commit 12ebe0ac38
4 changed files with 38 additions and 33 deletions

View File

@@ -553,7 +553,9 @@ class PlPlayerController {
/// 触发回调事件
for (var element in _statusListeners) {
element(event ? PlayerStatus.playing : PlayerStatus.paused);
if (element != null) {
element(event ? PlayerStatus.playing : PlayerStatus.paused);
}
}
if (videoPlayerController!.state.position.inSeconds != 0) {
makeHeartBeat(positionSeconds.value, type: 'status');