Revert "fix: #263"

This reverts commit 84ed34f3a7.
This commit is contained in:
bggRGjQaUbCoE
2025-02-16 00:26:01 +08:00
parent 00ea34f45d
commit 0f2b0cc5f2

View File

@@ -1280,76 +1280,72 @@ class _VideoDetailPageState extends State<VideoDetailPage>
), ),
), ),
), ),
child: Material( child: Row(
color: Theme.of(context).colorScheme.surface, children: [
child: Row( if (tabs.isEmpty)
children: [ const Spacer()
if (tabs.isEmpty) else
const Spacer()
else
Flexible(
flex: tabs.length == 3 ? 2 : 1,
child: showReply ? Obx(() => tabbar()) : tabbar(),
),
Flexible( Flexible(
flex: 1, flex: tabs.length == 3 ? 2 : 1,
child: Center( child: showReply ? Obx(() => tabbar()) : tabbar(),
child: Row( ),
mainAxisAlignment: MainAxisAlignment.end, Flexible(
children: [ flex: 1,
SizedBox( child: Center(
height: 32, child: Row(
child: TextButton( mainAxisAlignment: MainAxisAlignment.end,
style: ButtonStyle( children: [
padding: WidgetStateProperty.all(EdgeInsets.zero), SizedBox(
), height: 32,
onPressed: videoDetailController.showShootDanmakuSheet, child: TextButton(
child: Text( style: ButtonStyle(
'发弹幕', padding: WidgetStateProperty.all(EdgeInsets.zero),
style: TextStyle( ),
fontSize: 12, onPressed: videoDetailController.showShootDanmakuSheet,
color: child: Text(
Theme.of(context).colorScheme.onSurfaceVariant, '发弹幕',
), style: TextStyle(
fontSize: 12,
color: Theme.of(context).colorScheme.onSurfaceVariant,
), ),
), ),
), ),
SizedBox( ),
width: 38, SizedBox(
height: 38, width: 38,
child: Obx( height: 38,
() => IconButton( child: Obx(
onPressed: () { () => IconButton(
videoDetailController onPressed: () {
.plPlayerController.isOpenDanmu.value = videoDetailController
!videoDetailController .plPlayerController.isOpenDanmu.value =
.plPlayerController.isOpenDanmu.value; !videoDetailController
setting.put( .plPlayerController.isOpenDanmu.value;
SettingBoxKey.enableShowDanmaku, setting.put(
videoDetailController SettingBoxKey.enableShowDanmaku,
.plPlayerController.isOpenDanmu.value); videoDetailController
}, .plPlayerController.isOpenDanmu.value);
icon: SvgPicture.asset( },
videoDetailController icon: SvgPicture.asset(
.plPlayerController.isOpenDanmu.value videoDetailController
? 'assets/images/video/danmu_open.svg' .plPlayerController.isOpenDanmu.value
: 'assets/images/video/danmu_close.svg', ? 'assets/images/video/danmu_open.svg'
// ignore: deprecated_member_use : 'assets/images/video/danmu_close.svg',
color: videoDetailController // ignore: deprecated_member_use
.plPlayerController.isOpenDanmu.value color: videoDetailController
? Theme.of(context).colorScheme.secondary .plPlayerController.isOpenDanmu.value
: Theme.of(context).colorScheme.outline, ? Theme.of(context).colorScheme.secondary
), : Theme.of(context).colorScheme.outline,
), ),
), ),
), ),
const SizedBox(width: 14), ),
], const SizedBox(width: 14),
), ],
), ),
), ),
], ),
), ],
), ),
); );
} }