fix: controlsLock exit fullscreen

This commit is contained in:
guozhigq
2024-11-20 09:46:05 +08:00
parent 94fa0a1e6e
commit 4008b8caef
2 changed files with 7 additions and 1 deletions

View File

@ -684,6 +684,11 @@ class _VideoDetailPageState extends State<VideoDetailPage>
canPop: canPop:
plPlayerController?.isFullScreen.value != true, plPlayerController?.isFullScreen.value != true,
onPopInvoked: (bool didPop) { onPopInvoked: (bool didPop) {
if (plPlayerController?.controlsLock.value ==
true) {
plPlayerController?.onLockControl(false);
return;
}
if (plPlayerController?.isFullScreen.value == if (plPlayerController?.isFullScreen.value ==
true) { true) {
plPlayerController! plPlayerController!

View File

@ -909,7 +909,7 @@ class PlPlayerController {
if (videoType == 'live') { if (videoType == 'live') {
return; return;
} }
if (controlsLock.value) { if (_controlsLock.value) {
return; return;
} }
_doubleSpeedStatus.value = val; _doubleSpeedStatus.value = val;
@ -1081,6 +1081,7 @@ class PlPlayerController {
videoFitChangedTimer?.cancel(); videoFitChangedTimer?.cancel();
// _position.close(); // _position.close();
_playerEventSubs?.cancel(); _playerEventSubs?.cancel();
_controlsLock.value = false;
// _sliderPosition.close(); // _sliderPosition.close();
// _sliderTempPosition.close(); // _sliderTempPosition.close();
// _isSliderMoving.close(); // _isSliderMoving.close();