mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-04-20 03:06:59 +08:00
@@ -6,7 +6,6 @@ import 'dart:math';
|
||||
import 'package:PiliPlus/common/constants.dart';
|
||||
import 'package:PiliPlus/common/widgets/button/icon_button.dart';
|
||||
import 'package:PiliPlus/common/widgets/custom_icon.dart';
|
||||
import 'package:PiliPlus/common/widgets/custom_sliver_persistent_header_delegate.dart';
|
||||
import 'package:PiliPlus/common/widgets/dialog/report.dart';
|
||||
import 'package:PiliPlus/common/widgets/marquee.dart';
|
||||
import 'package:PiliPlus/http/danmaku.dart';
|
||||
@@ -1580,49 +1579,55 @@ class HeaderControlState extends State<HeaderControl>
|
||||
if (ctr == null) return;
|
||||
showBottomSheet((context, setState) {
|
||||
final theme = Theme.of(context);
|
||||
return Padding(
|
||||
padding: const EdgeInsets.all(12),
|
||||
child: Material(
|
||||
clipBehavior: Clip.hardEdge,
|
||||
return Container(
|
||||
margin: const EdgeInsets.all(12),
|
||||
decoration: BoxDecoration(
|
||||
color: theme.colorScheme.surface,
|
||||
borderRadius: const BorderRadius.all(Radius.circular(12)),
|
||||
child: CustomScrollView(
|
||||
slivers: [
|
||||
SliverPersistentHeader(
|
||||
pinned: true,
|
||||
delegate: CustomSliverPersistentHeaderDelegate(
|
||||
child: Container(
|
||||
height: 45,
|
||||
padding: const EdgeInsets.symmetric(horizontal: 14),
|
||||
decoration: BoxDecoration(
|
||||
border: Border(
|
||||
bottom: BorderSide(
|
||||
color: theme.colorScheme.outline.withValues(
|
||||
alpha: 0.1,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
const Text('弹幕列表'),
|
||||
iconButton(
|
||||
onPressed: () => setState(() {}),
|
||||
icon: const Icon(Icons.refresh),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
child: Column(
|
||||
children: [
|
||||
Container(
|
||||
height: 45,
|
||||
padding: const EdgeInsets.symmetric(horizontal: 14),
|
||||
decoration: BoxDecoration(
|
||||
border: Border(
|
||||
bottom: BorderSide(
|
||||
color: theme.colorScheme.outline.withValues(alpha: 0.1),
|
||||
),
|
||||
bgColor: theme.colorScheme.surface,
|
||||
),
|
||||
),
|
||||
?_buildDanmakuList(ctr.staticDanmaku.nonNulls.toList()),
|
||||
?_buildDanmakuList(ctr.scrollDanmaku.expand((e) => e).toList()),
|
||||
?_buildDanmakuList(ctr.specialDanmaku.toList()),
|
||||
const SliverToBoxAdapter(child: SizedBox(height: 12)),
|
||||
],
|
||||
),
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
const Text('弹幕列表'),
|
||||
iconButton(
|
||||
onPressed: () => setState(() {}),
|
||||
icon: const Icon(Icons.refresh),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
Expanded(
|
||||
child: Material(
|
||||
type: .transparency,
|
||||
clipBehavior: .hardEdge,
|
||||
borderRadius: const BorderRadius.vertical(
|
||||
bottom: Radius.circular(12),
|
||||
),
|
||||
child: CustomScrollView(
|
||||
slivers: [
|
||||
?_buildDanmakuList(ctr.staticDanmaku.nonNulls.toList()),
|
||||
?_buildDanmakuList(
|
||||
ctr.scrollDanmaku.expand((e) => e).toList(),
|
||||
),
|
||||
?_buildDanmakuList(ctr.specialDanmaku.toList()),
|
||||
const SliverToBoxAdapter(child: SizedBox(height: 12)),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user