From 12f90a411b7eff553391a4a41a9278c247ec7c09 Mon Sep 17 00:00:00 2001 From: guozhigq Date: Sat, 16 Dec 2023 22:12:12 +0800 Subject: [PATCH 1/2] =?UTF-8?q?fix:=20=E9=A6=96=E9=A1=B5=E6=8E=A8=E8=8D=90?= =?UTF-8?q?=E7=82=B9=E5=87=BB=E5=8A=A0=E8=BD=BD=E6=9B=B4=E5=A4=9A=E6=97=A0?= =?UTF-8?q?=E5=93=8D=E5=BA=94=20issues=20#270?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/pages/rcmd/view.dart | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/pages/rcmd/view.dart b/lib/pages/rcmd/view.dart index 1236ea33..717ea9f7 100644 --- a/lib/pages/rcmd/view.dart +++ b/lib/pages/rcmd/view.dart @@ -50,7 +50,6 @@ class _RcmdPageState extends State _rcmdController.onLoad(); }); } - final ScrollDirection direction = scrollController.position.userScrollDirection; if (direction == ScrollDirection.forward) { @@ -208,12 +207,13 @@ class LoadingMore extends StatelessWidget { child: GestureDetector( onTap: () { if (ctr != null) { + ctr!.isLoadingMore = true; ctr!.onLoad(); } }, child: Center( child: Text( - '加载更多 👇', + '点击加载更多 👇', style: TextStyle( color: Theme.of(context).colorScheme.outline, fontSize: 13), ), From 51254f57194d5f1063e33e48371079cafca11c34 Mon Sep 17 00:00:00 2001 From: guozhigq Date: Sun, 17 Dec 2023 22:58:00 +0800 Subject: [PATCH 2/2] =?UTF-8?q?fix:=20=E7=9B=B4=E6=92=AD=E9=9F=B3=E8=BD=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/plugin/pl_player/controller.dart | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/lib/plugin/pl_player/controller.dart b/lib/plugin/pl_player/controller.dart index 5ba1ccfb..80fd6671 100644 --- a/lib/plugin/pl_player/controller.dart +++ b/lib/plugin/pl_player/controller.dart @@ -375,9 +375,10 @@ class PlPlayerController { } Player player = _videoPlayerController ?? Player( - configuration: const PlayerConfiguration( + configuration: PlayerConfiguration( // 默认缓存 5M 大小 - bufferSize: 5 * 1024 * 1024, + bufferSize: + videoType.value == 'live' ? 32 * 1024 * 1024 : 5 * 1024 * 1024, ), ); @@ -390,6 +391,10 @@ class PlPlayerController { await pp.setProperty("ao", "audiotrack,opensles"); } + await player.setAudioTrack( + AudioTrack.auto(), + ); + // 音轨 if (dataSource.audioSource != '' && dataSource.audioSource != null) { await pp.setProperty( @@ -398,6 +403,11 @@ class PlPlayerController { ? dataSource.audioSource!.replaceAll(';', '\\;') : dataSource.audioSource!.replaceAll(':', '\\:'), ); + } else { + await pp.setProperty( + 'audio-files', + '', + ); } // 字幕