mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-05-30 23:58:13 +08:00
fix: 画面比例改变无法立即生效,删除冗余代码
This commit is contained in:
@@ -81,7 +81,6 @@ class PlPlayerController {
|
|||||||
|
|
||||||
final Rx<String> _direction = 'horizontal'.obs;
|
final Rx<String> _direction = 'horizontal'.obs;
|
||||||
|
|
||||||
Rx<bool> videoFitChanged = false.obs;
|
|
||||||
final Rx<BoxFit> _videoFit = Rx(BoxFit.contain);
|
final Rx<BoxFit> _videoFit = Rx(BoxFit.contain);
|
||||||
final Rx<String> _videoFitDesc = Rx('包含');
|
final Rx<String> _videoFitDesc = Rx('包含');
|
||||||
|
|
||||||
@@ -106,7 +105,6 @@ class PlPlayerController {
|
|||||||
Timer? _timerForShowingVolume;
|
Timer? _timerForShowingVolume;
|
||||||
Timer? _timerForGettingVolume;
|
Timer? _timerForGettingVolume;
|
||||||
Timer? timerForTrackingMouse;
|
Timer? timerForTrackingMouse;
|
||||||
Timer? videoFitChangedTimer;
|
|
||||||
|
|
||||||
// final Durations durations;
|
// final Durations durations;
|
||||||
|
|
||||||
@@ -1028,7 +1026,6 @@ class PlPlayerController {
|
|||||||
_timerForGettingVolume?.cancel();
|
_timerForGettingVolume?.cancel();
|
||||||
timerForTrackingMouse?.cancel();
|
timerForTrackingMouse?.cancel();
|
||||||
_timerForSeek?.cancel();
|
_timerForSeek?.cancel();
|
||||||
videoFitChangedTimer?.cancel();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 记录播放记录
|
// 记录播放记录
|
||||||
@@ -1079,7 +1076,6 @@ class PlPlayerController {
|
|||||||
_timerForGettingVolume?.cancel();
|
_timerForGettingVolume?.cancel();
|
||||||
timerForTrackingMouse?.cancel();
|
timerForTrackingMouse?.cancel();
|
||||||
_timerForSeek?.cancel();
|
_timerForSeek?.cancel();
|
||||||
videoFitChangedTimer?.cancel();
|
|
||||||
// _position.close();
|
// _position.close();
|
||||||
_playerEventSubs?.cancel();
|
_playerEventSubs?.cancel();
|
||||||
// _sliderPosition.close();
|
// _sliderPosition.close();
|
||||||
|
|||||||
@@ -223,6 +223,7 @@ class _PLVideoPlayerState extends State<PLVideoPlayer>
|
|||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Obx(
|
Obx(
|
||||||
() => Video(
|
() => Video(
|
||||||
|
key: ValueKey(_.videoFit.value),
|
||||||
controller: videoController,
|
controller: videoController,
|
||||||
controls: NoVideoControls,
|
controls: NoVideoControls,
|
||||||
pauseUponEnteringBackgroundMode: !enableBackgroundPlay,
|
pauseUponEnteringBackgroundMode: !enableBackgroundPlay,
|
||||||
|
|||||||
Reference in New Issue
Block a user