mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-06 09:13:48 +08:00
mod: video sheet
Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
@@ -113,24 +113,6 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
right: 12,
|
right: 12,
|
||||||
bottom: 12 + MediaQuery.paddingOf(context).bottom,
|
bottom: 12 + MediaQuery.paddingOf(context).bottom,
|
||||||
),
|
),
|
||||||
child: Column(
|
|
||||||
children: [
|
|
||||||
SizedBox(
|
|
||||||
height: 35,
|
|
||||||
child: Center(
|
|
||||||
child: Container(
|
|
||||||
width: 32,
|
|
||||||
height: 3,
|
|
||||||
decoration: BoxDecoration(
|
|
||||||
color: Theme.of(context)
|
|
||||||
.colorScheme
|
|
||||||
.onSecondaryContainer
|
|
||||||
.withOpacity(0.5),
|
|
||||||
borderRadius: const BorderRadius.all(Radius.circular(3))),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
Expanded(
|
|
||||||
child: Material(
|
child: Material(
|
||||||
color: Colors.transparent,
|
color: Colors.transparent,
|
||||||
child: MediaQuery.removePadding(
|
child: MediaQuery.removePadding(
|
||||||
@@ -138,6 +120,7 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
removeBottom: true,
|
removeBottom: true,
|
||||||
child: ListView(
|
child: ListView(
|
||||||
children: [
|
children: [
|
||||||
|
const SizedBox(height: 14),
|
||||||
// ListTile(
|
// ListTile(
|
||||||
// onTap: () {},
|
// onTap: () {},
|
||||||
// dense: true,
|
// dense: true,
|
||||||
@@ -171,15 +154,13 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
bvid: widget.videoDetailCtr.bvid);
|
bvid: widget.videoDetailCtr.bvid);
|
||||||
SmartDialog.showToast(res['msg']);
|
SmartDialog.showToast(res['msg']);
|
||||||
},
|
},
|
||||||
leading:
|
leading: const Icon(Icons.watch_later_outlined, size: 20),
|
||||||
const Icon(Icons.watch_later_outlined, size: 20),
|
|
||||||
title: const Text('添加至「稍后再看」', style: titleStyle),
|
title: const Text('添加至「稍后再看」', style: titleStyle),
|
||||||
),
|
),
|
||||||
ListTile(
|
ListTile(
|
||||||
dense: true,
|
dense: true,
|
||||||
onTap: () => {Get.back(), scheduleExit()},
|
onTap: () => {Get.back(), scheduleExit()},
|
||||||
leading:
|
leading: const Icon(Icons.hourglass_top_outlined, size: 20),
|
||||||
const Icon(Icons.hourglass_top_outlined, size: 20),
|
|
||||||
title: const Text('定时关闭', style: titleStyle),
|
title: const Text('定时关闭', style: titleStyle),
|
||||||
),
|
),
|
||||||
ListTile(
|
ListTile(
|
||||||
@@ -195,8 +176,7 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
),
|
),
|
||||||
ListTile(
|
ListTile(
|
||||||
dense: true,
|
dense: true,
|
||||||
leading: const Icon(
|
leading: const Icon(Icons.stay_current_landscape_outlined,
|
||||||
Icons.stay_current_landscape_outlined,
|
|
||||||
size: 20),
|
size: 20),
|
||||||
title: Row(
|
title: Row(
|
||||||
children: [
|
children: [
|
||||||
@@ -211,8 +191,8 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
const SizedBox(width: 10),
|
const SizedBox(width: 10),
|
||||||
Builder(
|
Builder(
|
||||||
builder: (context) => PopupMenuButton(
|
builder: (context) => PopupMenuButton(
|
||||||
initialValue: SuperResolutionType.values[
|
initialValue: SuperResolutionType
|
||||||
widget.controller.superResolutionType],
|
.values[widget.controller.superResolutionType],
|
||||||
child: Padding(
|
child: Padding(
|
||||||
padding: const EdgeInsets.all(4),
|
padding: const EdgeInsets.all(4),
|
||||||
child: Row(
|
child: Row(
|
||||||
@@ -220,26 +200,23 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
children: [
|
children: [
|
||||||
Text(
|
Text(
|
||||||
SuperResolutionType
|
SuperResolutionType
|
||||||
.values[widget
|
.values[
|
||||||
.controller.superResolutionType]
|
widget.controller.superResolutionType]
|
||||||
.title,
|
.title,
|
||||||
strutStyle:
|
strutStyle: StrutStyle(leading: 0, height: 1),
|
||||||
StrutStyle(leading: 0, height: 1),
|
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
height: 1,
|
height: 1,
|
||||||
fontSize: 14,
|
fontSize: 14,
|
||||||
color: Theme.of(context)
|
color:
|
||||||
.colorScheme
|
Theme.of(context).colorScheme.secondary,
|
||||||
.secondary,
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
Icon(
|
Icon(
|
||||||
MdiIcons.unfoldMoreHorizontal,
|
MdiIcons.unfoldMoreHorizontal,
|
||||||
size: MediaQuery.textScalerOf(context)
|
size: MediaQuery.textScalerOf(context)
|
||||||
.scale(14),
|
.scale(14),
|
||||||
color: Theme.of(context)
|
color:
|
||||||
.colorScheme
|
Theme.of(context).colorScheme.secondary,
|
||||||
.secondary,
|
|
||||||
)
|
)
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@@ -250,8 +227,7 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
(context as Element).markNeedsBuild();
|
(context as Element).markNeedsBuild();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
itemBuilder: (context) =>
|
itemBuilder: (context) => SuperResolutionType.values
|
||||||
SuperResolutionType.values
|
|
||||||
.map((item) => PopupMenuItem(
|
.map((item) => PopupMenuItem(
|
||||||
value: item,
|
value: item,
|
||||||
child: Text(item.title),
|
child: Text(item.title),
|
||||||
@@ -279,10 +255,7 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
title: 'CDN 设置',
|
title: 'CDN 设置',
|
||||||
value: defaultCDNService,
|
value: defaultCDNService,
|
||||||
values: CDNService.values.map((e) {
|
values: CDNService.values.map((e) {
|
||||||
return {
|
return {'title': e.description, 'value': e.code};
|
||||||
'title': e.description,
|
|
||||||
'value': e.code
|
|
||||||
};
|
|
||||||
}).toList());
|
}).toList());
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
@@ -326,9 +299,7 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
? Theme.of(context)
|
? Theme.of(context)
|
||||||
.colorScheme
|
.colorScheme
|
||||||
.onSecondaryContainer
|
.onSecondaryContainer
|
||||||
: Theme.of(context)
|
: Theme.of(context).colorScheme.outline,
|
||||||
.colorScheme
|
|
||||||
.outline,
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
onTap: () {
|
onTap: () {
|
||||||
@@ -344,18 +315,17 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
iconData: Icons.headphones,
|
iconData: Icons.headphones,
|
||||||
onTap: widget.controller.setOnlyPlayAudio,
|
onTap: widget.controller.setOnlyPlayAudio,
|
||||||
text: " 听视频 ",
|
text: " 听视频 ",
|
||||||
selectStatus:
|
selectStatus: widget.controller.onlyPlayAudio.value,
|
||||||
widget.controller.onlyPlayAudio.value,
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
3 => Obx(
|
3 => Obx(
|
||||||
() => ActionRowLineItem(
|
() => ActionRowLineItem(
|
||||||
iconData: Icons.play_circle_outline,
|
iconData: Icons.play_circle_outline,
|
||||||
onTap: widget
|
onTap:
|
||||||
.controller.setContinuePlayInBackground,
|
widget.controller.setContinuePlayInBackground,
|
||||||
text: " 后台播放 ",
|
text: " 后台播放 ",
|
||||||
selectStatus: widget.controller
|
selectStatus: widget
|
||||||
.continuePlayInBackground.value,
|
.controller.continuePlayInBackground.value,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
int() => throw UnimplementedError(),
|
int() => throw UnimplementedError(),
|
||||||
@@ -366,8 +336,7 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
ListTile(
|
ListTile(
|
||||||
dense: true,
|
dense: true,
|
||||||
onTap: () => {Get.back(), showSetVideoQa()},
|
onTap: () => {Get.back(), showSetVideoQa()},
|
||||||
leading:
|
leading: const Icon(Icons.play_circle_outline, size: 20),
|
||||||
const Icon(Icons.play_circle_outline, size: 20),
|
|
||||||
title: const Text('选择画质', style: titleStyle),
|
title: const Text('选择画质', style: titleStyle),
|
||||||
subtitle: Text(
|
subtitle: Text(
|
||||||
'当前画质 ${widget.videoDetailCtr.currentVideoQa.description}',
|
'当前画质 ${widget.videoDetailCtr.currentVideoQa.description}',
|
||||||
@@ -411,8 +380,7 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
title: const Text('播放信息', style: titleStyle),
|
title: const Text('播放信息', style: titleStyle),
|
||||||
leading: const Icon(Icons.info_outline, size: 20),
|
leading: const Icon(Icons.info_outline, size: 20),
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Player? player =
|
Player? player = widget.controller.videoPlayerController;
|
||||||
widget.controller.videoPlayerController;
|
|
||||||
if (player == null) {
|
if (player == null) {
|
||||||
SmartDialog.showToast('播放器未初始化');
|
SmartDialog.showToast('播放器未初始化');
|
||||||
return;
|
return;
|
||||||
@@ -441,8 +409,8 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
ListTile(
|
ListTile(
|
||||||
dense: true,
|
dense: true,
|
||||||
title: const Text("VideoParams"),
|
title: const Text("VideoParams"),
|
||||||
subtitle: Text(player.state.videoParams
|
subtitle:
|
||||||
.toString()),
|
Text(player.state.videoParams.toString()),
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Utils.copyText(
|
Utils.copyText(
|
||||||
'VideoParams\n${player.state.videoParams}',
|
'VideoParams\n${player.state.videoParams}',
|
||||||
@@ -453,8 +421,8 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
ListTile(
|
ListTile(
|
||||||
dense: true,
|
dense: true,
|
||||||
title: const Text("AudioParams"),
|
title: const Text("AudioParams"),
|
||||||
subtitle: Text(player.state.audioParams
|
subtitle:
|
||||||
.toString()),
|
Text(player.state.audioParams.toString()),
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Utils.copyText(
|
Utils.copyText(
|
||||||
'AudioParams\n${player.state.audioParams}',
|
'AudioParams\n${player.state.audioParams}',
|
||||||
@@ -465,8 +433,8 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
ListTile(
|
ListTile(
|
||||||
dense: true,
|
dense: true,
|
||||||
title: const Text("Media"),
|
title: const Text("Media"),
|
||||||
subtitle: Text(
|
subtitle:
|
||||||
player.state.playlist.toString()),
|
Text(player.state.playlist.toString()),
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Utils.copyText(
|
Utils.copyText(
|
||||||
'Media\n${player.state.playlist}',
|
'Media\n${player.state.playlist}',
|
||||||
@@ -477,8 +445,8 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
ListTile(
|
ListTile(
|
||||||
dense: true,
|
dense: true,
|
||||||
title: const Text("AudioTrack"),
|
title: const Text("AudioTrack"),
|
||||||
subtitle: Text(player.state.track.audio
|
subtitle:
|
||||||
.toString()),
|
Text(player.state.track.audio.toString()),
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Utils.copyText(
|
Utils.copyText(
|
||||||
'AudioTrack\n${player.state.track.audio}',
|
'AudioTrack\n${player.state.track.audio}',
|
||||||
@@ -489,8 +457,8 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
ListTile(
|
ListTile(
|
||||||
dense: true,
|
dense: true,
|
||||||
title: const Text("VideoTrack"),
|
title: const Text("VideoTrack"),
|
||||||
subtitle: Text(player.state.track.video
|
subtitle:
|
||||||
.toString()),
|
Text(player.state.track.video.toString()),
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Utils.copyText(
|
Utils.copyText(
|
||||||
'VideoTrack\n${player.state.track.audio}',
|
'VideoTrack\n${player.state.track.audio}',
|
||||||
@@ -501,8 +469,8 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
ListTile(
|
ListTile(
|
||||||
dense: true,
|
dense: true,
|
||||||
title: const Text("pitch"),
|
title: const Text("pitch"),
|
||||||
subtitle: Text(
|
subtitle:
|
||||||
player.state.pitch.toString()),
|
Text(player.state.pitch.toString()),
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Utils.copyText(
|
Utils.copyText(
|
||||||
'pitch\n${player.state.pitch}',
|
'pitch\n${player.state.pitch}',
|
||||||
@@ -512,8 +480,8 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
ListTile(
|
ListTile(
|
||||||
dense: true,
|
dense: true,
|
||||||
title: const Text("rate"),
|
title: const Text("rate"),
|
||||||
subtitle: Text(
|
subtitle:
|
||||||
player.state.rate.toString()),
|
Text(player.state.rate.toString()),
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Utils.copyText(
|
Utils.copyText(
|
||||||
'rate\n${player.state.rate}',
|
'rate\n${player.state.rate}',
|
||||||
@@ -523,8 +491,8 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
ListTile(
|
ListTile(
|
||||||
dense: true,
|
dense: true,
|
||||||
title: const Text("AudioBitrate"),
|
title: const Text("AudioBitrate"),
|
||||||
subtitle: Text(player.state.audioBitrate
|
subtitle: Text(
|
||||||
.toString()),
|
player.state.audioBitrate.toString()),
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Utils.copyText(
|
Utils.copyText(
|
||||||
'AudioBitrate\n${player.state.audioBitrate}',
|
'AudioBitrate\n${player.state.audioBitrate}',
|
||||||
@@ -535,8 +503,8 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
ListTile(
|
ListTile(
|
||||||
dense: true,
|
dense: true,
|
||||||
title: const Text("Volume"),
|
title: const Text("Volume"),
|
||||||
subtitle: Text(
|
subtitle:
|
||||||
player.state.volume.toString()),
|
Text(player.state.volume.toString()),
|
||||||
onTap: () {
|
onTap: () {
|
||||||
Utils.copyText(
|
Utils.copyText(
|
||||||
'Volume\n${player.state.volume}',
|
'Volume\n${player.state.volume}',
|
||||||
@@ -553,9 +521,8 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
child: Text(
|
child: Text(
|
||||||
'确定',
|
'确定',
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
color: Theme.of(context)
|
color:
|
||||||
.colorScheme
|
Theme.of(context).colorScheme.outline),
|
||||||
.outline),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
@@ -586,9 +553,6 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -619,7 +583,7 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
child: Column(
|
child: Column(
|
||||||
crossAxisAlignment: CrossAxisAlignment.start,
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
children: [
|
children: [
|
||||||
const SizedBox(height: 30),
|
const SizedBox(height: 10),
|
||||||
const Center(child: Text('定时关闭', style: titleStyle)),
|
const Center(child: Text('定时关闭', style: titleStyle)),
|
||||||
const SizedBox(height: 10),
|
const SizedBox(height: 10),
|
||||||
...[
|
...[
|
||||||
@@ -1149,8 +1113,7 @@ class _HeaderControlState extends State<HeaderControl> {
|
|||||||
Get.toNamed('/danmakuBlock',
|
Get.toNamed('/danmakuBlock',
|
||||||
arguments: widget.controller)
|
arguments: widget.controller)
|
||||||
},
|
},
|
||||||
child: Text(
|
child: Text("屏蔽管理(${widget.controller.filterCount})")),
|
||||||
"屏蔽管理(${widget.controller.filterCount})")),
|
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
Padding(
|
Padding(
|
||||||
|
|||||||
Reference in New Issue
Block a user