fix:播放异常黑屏等

This commit is contained in:
orz12
2024-03-13 18:38:09 +08:00
parent 766b85cff1
commit cc6da716bc
9 changed files with 50 additions and 35 deletions

View File

@@ -268,7 +268,9 @@ class VideoDetailController extends GetxController
// 硬解
enableHA: enableHA.value,
seekTo: seekToTime ?? defaultST,
duration: duration ?? Duration(milliseconds: data.timeLength ?? 0),
duration: duration ?? data.timeLength == null
? null
: Duration(milliseconds: data.timeLength!),
// 宽>高 水平 否则 垂直
direction: firstVideo.width != null && firstVideo.height != null
? ((firstVideo.width! - firstVideo.height!) > 0