Merge branch 'feature-watchLater'

This commit is contained in:
guozhigq
2024-12-02 22:46:39 +08:00
2 changed files with 5 additions and 8 deletions

View File

@ -624,10 +624,8 @@ class VideoDetailController extends GetxController
}
void toggeleWatchLaterVisible(bool val) {
if (sourceType.value == 'watchLater' ||
sourceType.value == 'fav' ||
sourceType.value == 'up_archive') {
isWatchLaterVisible.value = !isWatchLaterVisible.value;
if (['watchLater', 'fav', 'up_archive'].contains(sourceType.value)) {
isWatchLaterVisible.value = val;
}
}

View File

@ -206,12 +206,12 @@ class _VideoDetailPageState extends State<VideoDetailPage>
vdCtr.bottomList.insert(3, BottomControlType.episode);
}
}
vdCtr.toggeleWatchLaterVisible(false);
} else {
if (vdCtr.bottomList.contains(BottomControlType.episode)) {
vdCtr.bottomList.removeAt(3);
}
}
vdCtr.toggeleWatchLaterVisible(!isFullScreen);
});
}
@ -830,9 +830,8 @@ class _VideoDetailPageState extends State<VideoDetailPage>
/// 稍后再看列表
Obx(
() => Visibility(
visible: vdCtr.sourceType.value == 'watchLater' ||
vdCtr.sourceType.value == 'fav' ||
vdCtr.sourceType.value == 'up_archive',
visible: ['watchLater', 'fav', 'up_archive']
.contains(vdCtr.sourceType.value),
child: AnimatedPositioned(
duration: const Duration(milliseconds: 400),
curve: Curves.easeInOut,