mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-06 09:13:48 +08:00
mod: 侧边栏、动态重构,排行改为首页分区,平板、折叠屏、竖屏视频新适配,播放页可隐藏黑边、截图、点踩,弹幕粗细调整,默认关闭后台播放,弹窗接受返回
This commit is contained in:
@@ -48,17 +48,16 @@ class SettingController extends GetxController {
|
||||
setting.get(SettingBoxKey.defaultHomePage, defaultValue: 0);
|
||||
}
|
||||
|
||||
loginOut() async {
|
||||
SmartDialog.show(
|
||||
useSystem: true,
|
||||
animationType: SmartAnimationType.centerFade_otherSlide,
|
||||
builder: (BuildContext context) {
|
||||
loginOut(BuildContext context) async {
|
||||
await showDialog(
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return AlertDialog(
|
||||
title: const Text('提示'),
|
||||
content: const Text('确认要退出登录吗'),
|
||||
actions: [
|
||||
TextButton(
|
||||
onPressed: () => SmartDialog.dismiss(),
|
||||
onPressed: () => Get.back(),
|
||||
child: const Text('点错了'),
|
||||
),
|
||||
TextButton(
|
||||
@@ -73,7 +72,7 @@ class SettingController extends GetxController {
|
||||
.put(LocalCacheKey.accessKey, {'mid': -1, 'value': ''});
|
||||
|
||||
await LoginUtils.refreshLoginStatus(false);
|
||||
SmartDialog.dismiss().then((value) => Get.back());
|
||||
Get.back();
|
||||
},
|
||||
child: const Text('确认'),
|
||||
)
|
||||
|
||||
@@ -54,10 +54,9 @@ class _ExtraSettingState extends State<ExtraSetting> {
|
||||
var systemProxyHost = '';
|
||||
var systemProxyPort = '';
|
||||
|
||||
SmartDialog.show(
|
||||
useSystem: true,
|
||||
animationType: SmartAnimationType.centerFade_otherSlide,
|
||||
builder: (BuildContext context) {
|
||||
showDialog(
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return AlertDialog(
|
||||
title: const Text('设置代理'),
|
||||
content: Column(
|
||||
@@ -101,7 +100,7 @@ class _ExtraSettingState extends State<ExtraSetting> {
|
||||
actions: [
|
||||
TextButton(
|
||||
onPressed: () async {
|
||||
SmartDialog.dismiss();
|
||||
Get.back();
|
||||
},
|
||||
child: Text(
|
||||
'取消',
|
||||
@@ -112,7 +111,7 @@ class _ExtraSettingState extends State<ExtraSetting> {
|
||||
onPressed: () async {
|
||||
setting.put(SettingBoxKey.systemProxyHost, systemProxyHost);
|
||||
setting.put(SettingBoxKey.systemProxyPort, systemProxyPort);
|
||||
SmartDialog.dismiss();
|
||||
Get.back();
|
||||
// Request.dio;
|
||||
},
|
||||
child: const Text('确认'),
|
||||
@@ -210,6 +209,13 @@ class _ExtraSettingState extends State<ExtraSetting> {
|
||||
setKey: SettingBoxKey.disableLikeMsg,
|
||||
defaultVal: false,
|
||||
),
|
||||
const SetSwitchItem(
|
||||
title: '默认展示评论区',
|
||||
subTitle: '在视频详情页默认切换至评论区页(仅tab型布局)',
|
||||
leading: Icon(Icons.mode_comment_outlined),
|
||||
setKey: SettingBoxKey.defaultShowComment,
|
||||
defaultVal: false,
|
||||
),
|
||||
ListTile(
|
||||
dense: false,
|
||||
title: Text('评论展示', style: titleStyle),
|
||||
|
||||
@@ -12,7 +12,8 @@ class FontSizeSelectPage extends StatefulWidget {
|
||||
|
||||
class _FontSizeSelectPageState extends State<FontSizeSelectPage> {
|
||||
Box setting = GStrorage.setting;
|
||||
List<double> list = [0.9, 0.95, 1.0, 1.05, 1.1, 1.15, 1.2, 1.25, 1.3];
|
||||
List<double> list = List.generate(12, (index) => 0.85 + index * 0.05);
|
||||
//[0.85, 0.9, 0.95, 1.0, 1.05, 1.1, 1.15, 1.2, 1.25, 1.3, 1.35];
|
||||
late double minsize;
|
||||
late double maxSize;
|
||||
late double currentSize;
|
||||
|
||||
@@ -21,7 +21,7 @@ class _TabbarSetPageState extends State<TabbarSetPage> {
|
||||
super.initState();
|
||||
defaultTabs = tabsConfig;
|
||||
tabbarSort = settingStorage.get(SettingBoxKey.tabbarSort,
|
||||
defaultValue: ['live', 'rcmd', 'hot', 'bangumi']);
|
||||
defaultValue: ['live', 'rcmd', 'hot', 'rank', 'bangumi']);
|
||||
// 对 tabData 进行排序
|
||||
defaultTabs.sort((a, b) {
|
||||
int indexA = tabbarSort.indexOf((a['type'] as TabType).id);
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_smart_dialog/flutter_smart_dialog.dart';
|
||||
import 'package:get/get.dart';
|
||||
import 'package:hive/hive.dart';
|
||||
import 'package:PiliPalaX/pages/setting/widgets/switch_item.dart';
|
||||
import 'package:PiliPalaX/plugin/pl_player/index.dart';
|
||||
@@ -76,10 +77,9 @@ class _PlaySpeedPageState extends State<PlaySpeedPage> {
|
||||
// 添加自定义倍速
|
||||
void onAddSpeed() {
|
||||
double customSpeed = 1.0;
|
||||
SmartDialog.show(
|
||||
useSystem: true,
|
||||
animationType: SmartAnimationType.centerFade_otherSlide,
|
||||
builder: (BuildContext context) {
|
||||
showDialog(
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return AlertDialog(
|
||||
title: const Text('添加倍速'),
|
||||
content: Column(
|
||||
@@ -103,7 +103,7 @@ class _PlaySpeedPageState extends State<PlaySpeedPage> {
|
||||
),
|
||||
actions: [
|
||||
TextButton(
|
||||
onPressed: () => SmartDialog.dismiss(),
|
||||
onPressed: () => Get.back(),
|
||||
child: const Text('取消'),
|
||||
),
|
||||
TextButton(
|
||||
@@ -112,7 +112,7 @@ class _PlaySpeedPageState extends State<PlaySpeedPage> {
|
||||
await videoStorage.put(
|
||||
VideoBoxKey.customSpeedsList, customSpeedsList);
|
||||
setState(() {});
|
||||
SmartDialog.dismiss();
|
||||
Get.back();
|
||||
},
|
||||
child: const Text('确认添加'),
|
||||
)
|
||||
|
||||
@@ -120,7 +120,7 @@ class _PlaySettingState extends State<PlaySetting> {
|
||||
),
|
||||
const SetSwitchItem(
|
||||
title: '竖屏扩大展示',
|
||||
subTitle: '小屏竖屏视频宽高比由16:9扩大至4:5(!暂不支持临时收起)',
|
||||
subTitle: '小屏竖屏视频宽高比由16:9扩大至1:1(不支持收起);横屏适配时,扩大至9:16',
|
||||
leading: Icon(Icons.expand_outlined),
|
||||
setKey: SettingBoxKey.enableVerticalExpand,
|
||||
defaultVal: false,
|
||||
@@ -151,7 +151,7 @@ class _PlaySettingState extends State<PlaySetting> {
|
||||
subTitle: '进入后台时继续播放',
|
||||
leading: Icon(Icons.motion_photos_pause_outlined),
|
||||
setKey: SettingBoxKey.continuePlayInBackground,
|
||||
defaultVal: true,
|
||||
defaultVal: false,
|
||||
),
|
||||
if (Platform.isAndroid)
|
||||
SetSwitchItem(
|
||||
|
||||
@@ -121,7 +121,8 @@ class _PrivacySettingState extends State<PrivacySetting> {
|
||||
)),
|
||||
ListTile(
|
||||
onTap: () {
|
||||
SmartDialog.show(
|
||||
showDialog(
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return AlertDialog(
|
||||
title: const Text('查看详情'),
|
||||
@@ -130,7 +131,7 @@ class _PrivacySettingState extends State<PrivacySetting> {
|
||||
actions: [
|
||||
TextButton(
|
||||
onPressed: () async {
|
||||
SmartDialog.dismiss();
|
||||
Get.back();
|
||||
},
|
||||
child: const Text('确认'),
|
||||
)
|
||||
@@ -150,9 +151,9 @@ class _PrivacySettingState extends State<PrivacySetting> {
|
||||
}
|
||||
|
||||
void import_export_cookies(TextStyle titleStyle, TextStyle subTitleStyle) {
|
||||
SmartDialog.show(
|
||||
useSystem: true,
|
||||
builder: (BuildContext context) {
|
||||
showDialog(
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return SimpleDialog(
|
||||
title: const Text('导入/导出cookie', style: TextStyle(color: Colors.red)),
|
||||
children: [
|
||||
@@ -175,13 +176,14 @@ class _PrivacySettingState extends State<PrivacySetting> {
|
||||
),
|
||||
dense: false,
|
||||
onTap: () async {
|
||||
await SmartDialog.dismiss();
|
||||
Navigator.of(context).pop();
|
||||
if (!userLogin) {
|
||||
SmartDialog.showToast('请先登录');
|
||||
return;
|
||||
}
|
||||
final String cookie = await CookieTool.exportCookie();
|
||||
await SmartDialog.show(
|
||||
await showDialog(
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return AlertDialog(
|
||||
title: const Text('导出cookie(危险)',
|
||||
@@ -190,7 +192,7 @@ class _PrivacySettingState extends State<PrivacySetting> {
|
||||
actions: [
|
||||
TextButton(
|
||||
onPressed: () async {
|
||||
await SmartDialog.dismiss();
|
||||
Navigator.of(context).pop();
|
||||
await Clipboard.setData(
|
||||
ClipboardData(text: cookie));
|
||||
},
|
||||
@@ -199,7 +201,7 @@ class _PrivacySettingState extends State<PrivacySetting> {
|
||||
),
|
||||
TextButton(
|
||||
onPressed: () async {
|
||||
await SmartDialog.dismiss();
|
||||
Navigator.of(context).pop();
|
||||
},
|
||||
child: const Text('取消'),
|
||||
),
|
||||
@@ -223,13 +225,14 @@ class _PrivacySettingState extends State<PrivacySetting> {
|
||||
),
|
||||
dense: false,
|
||||
onTap: () async {
|
||||
await SmartDialog.dismiss();
|
||||
ClipboardData? data = await Clipboard.getData('text/plain');
|
||||
if (data == null || data.text == null || data.text == '') {
|
||||
SmartDialog.showToast('未检测到剪贴板内容');
|
||||
return;
|
||||
}
|
||||
await SmartDialog.show(
|
||||
if (!context.mounted) return;
|
||||
await showDialog(
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return AlertDialog(
|
||||
title: const Text('导入剪贴板中的cookie'),
|
||||
@@ -237,13 +240,13 @@ class _PrivacySettingState extends State<PrivacySetting> {
|
||||
actions: [
|
||||
TextButton(
|
||||
onPressed: () async {
|
||||
await SmartDialog.dismiss();
|
||||
Get.back();
|
||||
},
|
||||
child: const Text('取消'),
|
||||
),
|
||||
TextButton(
|
||||
onPressed: () async {
|
||||
await SmartDialog.dismiss();
|
||||
Get.back();
|
||||
final String cookie = data.text!;
|
||||
try {
|
||||
await CookieTool.importCookie(cookie);
|
||||
|
||||
@@ -6,6 +6,7 @@ import 'package:PiliPalaX/models/common/rcmd_type.dart';
|
||||
import 'package:PiliPalaX/pages/setting/widgets/select_dialog.dart';
|
||||
import 'package:PiliPalaX/utils/recommend_filter.dart';
|
||||
import 'package:PiliPalaX/utils/storage.dart';
|
||||
import 'package:get/get.dart';
|
||||
|
||||
import 'widgets/switch_item.dart';
|
||||
|
||||
@@ -93,8 +94,9 @@ class _RecommendSettingState extends State<RecommendSetting> {
|
||||
return;
|
||||
}
|
||||
// 显示一个确认框,告知用户可能会导致账号被风控
|
||||
SmartDialog.show(
|
||||
animationType: SmartAnimationType.centerFade_otherSlide,
|
||||
if (!context.mounted) return;
|
||||
await showDialog(
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return AlertDialog(
|
||||
title: const Text('提示'),
|
||||
@@ -104,14 +106,20 @@ class _RecommendSettingState extends State<RecommendSetting> {
|
||||
TextButton(
|
||||
onPressed: () {
|
||||
result = null;
|
||||
SmartDialog.dismiss();
|
||||
Get.back();
|
||||
},
|
||||
child: const Text('取消'),
|
||||
),
|
||||
TextButton(
|
||||
onPressed: () async {
|
||||
SmartDialog.dismiss();
|
||||
await MemberHttp.cookieToKey();
|
||||
Get.back();
|
||||
var res = await MemberHttp.cookieToKey();
|
||||
if (res['status']) {
|
||||
SmartDialog.showToast(res['msg']);
|
||||
} else {
|
||||
SmartDialog.showToast(
|
||||
'获取access_key失败:${res['msg']}');
|
||||
}
|
||||
},
|
||||
child: const Text('确定'),
|
||||
),
|
||||
@@ -254,10 +262,9 @@ class _RecommendSettingState extends State<RecommendSetting> {
|
||||
'* 其它(如热门视频、手动搜索、链接跳转等)均不受过滤器影响。\n'
|
||||
'* 设定较严苛的条件可导致推荐项数锐减或多次请求,请酌情选择。\n'
|
||||
'* 后续可能会增加更多过滤条件,敬请期待。',
|
||||
style: Theme.of(context)
|
||||
.textTheme
|
||||
.labelSmall!
|
||||
.copyWith(color: Theme.of(context).colorScheme.outline.withOpacity(0.7)),
|
||||
style: Theme.of(context).textTheme.labelSmall!.copyWith(
|
||||
color:
|
||||
Theme.of(context).colorScheme.outline.withOpacity(0.7)),
|
||||
),
|
||||
)
|
||||
],
|
||||
|
||||
@@ -13,6 +13,7 @@ import 'package:PiliPalaX/utils/global_data.dart';
|
||||
import 'package:PiliPalaX/utils/storage.dart';
|
||||
|
||||
import '../../models/common/dynamic_badge_mode.dart';
|
||||
import '../../models/common/up_panel_position.dart';
|
||||
import '../../plugin/pl_player/utils/fullscreen.dart';
|
||||
import '../../models/common/nav_bar_config.dart';
|
||||
import 'controller.dart';
|
||||
@@ -34,13 +35,18 @@ class _StyleSettingState extends State<StyleSetting> {
|
||||
late int picQuality;
|
||||
late ThemeType _tempThemeValue;
|
||||
late double maxRowWidth;
|
||||
late UpPanelPosition upPanelPosition;
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
picQuality = setting.get(SettingBoxKey.defaultPicQa, defaultValue: 10);
|
||||
_tempThemeValue = settingController.themeType.value;
|
||||
maxRowWidth = setting.get(SettingBoxKey.maxRowWidth, defaultValue: 240.0) as double;
|
||||
maxRowWidth =
|
||||
setting.get(SettingBoxKey.maxRowWidth, defaultValue: 240.0) as double;
|
||||
upPanelPosition = UpPanelPosition.values[setting.get(
|
||||
SettingBoxKey.upPanelPosition,
|
||||
defaultValue: UpPanelPosition.leftFixed.code)];
|
||||
}
|
||||
|
||||
@override
|
||||
@@ -70,15 +76,15 @@ class _StyleSettingState extends State<StyleSetting> {
|
||||
callFn: (value) {
|
||||
if (value) {
|
||||
autoScreen();
|
||||
SmartDialog.showToast('已开启横屏适配');
|
||||
SmartDialog.showToast('已开启横屏适配,推荐将全屏方式设为【不改变当前方向】');
|
||||
} else {
|
||||
AutoOrientation.portraitUpMode();
|
||||
SmartDialog.showToast('已关闭横屏适配');
|
||||
}
|
||||
}),
|
||||
const SetSwitchItem(
|
||||
title: '自适应底栏/侧边栏',
|
||||
subTitle: '横竖屏自动切换(其它底栏设置失效)',
|
||||
title: '改用侧边栏',
|
||||
subTitle: '开启后底栏被替换,且底栏相关设置失效',
|
||||
leading: Icon(Icons.chrome_reader_mode_outlined),
|
||||
setKey: SettingBoxKey.adaptiveNavBar,
|
||||
defaultVal: false,
|
||||
@@ -90,6 +96,94 @@ class _StyleSettingState extends State<StyleSetting> {
|
||||
setKey: SettingBoxKey.enableMYBar,
|
||||
defaultVal: true,
|
||||
),
|
||||
const SetSwitchItem(
|
||||
title: '首页背景渐变',
|
||||
setKey: SettingBoxKey.enableGradientBg,
|
||||
leading: Icon(Icons.gradient_outlined),
|
||||
defaultVal: true,
|
||||
needReboot: true,
|
||||
),
|
||||
ListTile(
|
||||
onTap: () async {
|
||||
double? result = await showDialog(
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return SlideDialog<double>(
|
||||
title: '最大列宽度(默认240dp)',
|
||||
value: maxRowWidth,
|
||||
min: 150.0,
|
||||
max: 500.0,
|
||||
divisions: 35,
|
||||
suffix: 'dp',
|
||||
);
|
||||
});
|
||||
if (result != null) {
|
||||
maxRowWidth = result;
|
||||
setting.put(SettingBoxKey.maxRowWidth, result);
|
||||
SmartDialog.showToast('重启生效');
|
||||
setState(() {});
|
||||
}
|
||||
},
|
||||
leading: const Icon(Icons.calendar_view_week_outlined),
|
||||
dense: false,
|
||||
title: Text('列表宽度(dp)限制', style: titleStyle),
|
||||
subtitle: Text(
|
||||
'当前:${maxRowWidth.toInt()}dp,屏幕宽度:${MediaQuery.of(context).size.width.toPrecision(2)}dp。'
|
||||
'宽度越小列数越多,横条、大卡会2倍折算',
|
||||
style: subTitleStyle,
|
||||
),
|
||||
),
|
||||
const SetSwitchItem(
|
||||
title: '播放页移除安全边距',
|
||||
subTitle: '隐藏状态栏、撑满屏幕,但播放控件仍处于安全域内',
|
||||
leading: Icon(Icons.crop_outlined),
|
||||
setKey: SettingBoxKey.videoPlayerRemoveSafeArea,
|
||||
defaultVal: false,
|
||||
needReboot: true,
|
||||
),
|
||||
const SetSwitchItem(
|
||||
title: '动态页启用瀑布流',
|
||||
subTitle: '关闭会显示为单列',
|
||||
leading: Icon(Icons.view_array_outlined),
|
||||
setKey: SettingBoxKey.dynamicsWaterfallFlow,
|
||||
defaultVal: true,
|
||||
needReboot: true,
|
||||
),
|
||||
ListTile(
|
||||
dense: false,
|
||||
title: Text('动态页Up主显示位置', style: titleStyle),
|
||||
leading: const Icon(Icons.person_outlined),
|
||||
subtitle: Text('当前:${upPanelPosition.labels}', style: subTitleStyle),
|
||||
onTap: () async {
|
||||
UpPanelPosition? result = await showDialog(
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return SelectDialog<UpPanelPosition>(
|
||||
title: '动态页Up主显示位置',
|
||||
value: upPanelPosition,
|
||||
values: UpPanelPosition.values.map((e) {
|
||||
return {'title': e.labels, 'value': e};
|
||||
}).toList(),
|
||||
);
|
||||
},
|
||||
);
|
||||
if (result != null) {
|
||||
upPanelPosition = result;
|
||||
setting.put(SettingBoxKey.upPanelPosition, result.code);
|
||||
SmartDialog.showToast('重启生效');
|
||||
setState(() {});
|
||||
}
|
||||
},
|
||||
),
|
||||
ListTile(
|
||||
dense: false,
|
||||
onTap: () => settingController.setDynamicBadgeMode(context),
|
||||
title: Text('动态未读标记', style: titleStyle),
|
||||
leading: const Icon(Icons.motion_photos_on_outlined),
|
||||
subtitle: Obx(() => Text(
|
||||
'当前标记样式:${settingController.dynamicBadgeType.value.description}',
|
||||
style: subTitleStyle)),
|
||||
),
|
||||
const SetSwitchItem(
|
||||
title: '首页顶栏收起',
|
||||
subTitle: '首页列表滑动时,收起顶栏',
|
||||
@@ -106,44 +200,6 @@ class _StyleSettingState extends State<StyleSetting> {
|
||||
defaultVal: false,
|
||||
needReboot: true,
|
||||
),
|
||||
const SetSwitchItem(
|
||||
title: '首页背景渐变',
|
||||
setKey: SettingBoxKey.enableGradientBg,
|
||||
leading: Icon(Icons.gradient_outlined),
|
||||
defaultVal: true,
|
||||
needReboot: true,
|
||||
),
|
||||
ListTile(
|
||||
onTap: () async {
|
||||
double? result = await showDialog(
|
||||
context: context,
|
||||
builder: (context) {
|
||||
return SlideDialog<double>(
|
||||
title: '最大列宽度(默认240dp)',
|
||||
value: maxRowWidth,
|
||||
min: 150.0,
|
||||
max: 500.0,
|
||||
divisions: 35,
|
||||
suffix: 'dp',
|
||||
);
|
||||
}
|
||||
);
|
||||
if (result != null) {
|
||||
maxRowWidth = result;
|
||||
setting.put(SettingBoxKey.maxRowWidth, result);
|
||||
SmartDialog.showToast('重启生效');
|
||||
setState(() {});
|
||||
}
|
||||
},
|
||||
leading: const Icon(Icons.calendar_view_week_outlined),
|
||||
dense: false,
|
||||
title: Text('列表宽度(dp)上限', style: titleStyle),
|
||||
subtitle: Text(
|
||||
'当前:${maxRowWidth.toInt()}dp,屏幕宽度:${MediaQuery.of(context).size.width.toPrecision(2)}dp。'
|
||||
'宽度越小列数越多,横条、大卡会2倍折算',
|
||||
style: subTitleStyle,
|
||||
),
|
||||
),
|
||||
ListTile(
|
||||
dense: false,
|
||||
onTap: () {
|
||||
@@ -235,6 +291,9 @@ class _StyleSettingState extends State<StyleSetting> {
|
||||
leading: const Icon(Icons.opacity_outlined),
|
||||
title: Text('气泡提示不透明度', style: titleStyle),
|
||||
subtitle: Text('自定义气泡提示(Toast)不透明度', style: subTitleStyle),
|
||||
trailing: Obx(() => Text(
|
||||
settingController.toastOpacity.value.toStringAsFixed(1),
|
||||
style: Theme.of(context).textTheme.titleSmall)),
|
||||
),
|
||||
ListTile(
|
||||
dense: false,
|
||||
@@ -263,15 +322,6 @@ class _StyleSettingState extends State<StyleSetting> {
|
||||
'当前模式:${settingController.themeType.value.description}',
|
||||
style: subTitleStyle)),
|
||||
),
|
||||
ListTile(
|
||||
dense: false,
|
||||
onTap: () => settingController.setDynamicBadgeMode(context),
|
||||
title: Text('动态未读标记', style: titleStyle),
|
||||
leading: const Icon(Icons.motion_photos_on_outlined),
|
||||
subtitle: Obx(() => Text(
|
||||
'当前标记样式:${settingController.dynamicBadgeType.value.description}',
|
||||
style: subTitleStyle)),
|
||||
),
|
||||
ListTile(
|
||||
dense: false,
|
||||
onTap: () => Get.toNamed('/colorSetting'),
|
||||
@@ -281,13 +331,6 @@ class _StyleSettingState extends State<StyleSetting> {
|
||||
'当前主题:${colorSelectController.type.value == 0 ? '动态取色' : '指定颜色'}',
|
||||
style: subTitleStyle)),
|
||||
),
|
||||
const SetSwitchItem(
|
||||
title: '默认展示评论区',
|
||||
subTitle: '在视频详情页默认切换至评论区页',
|
||||
leading: Icon(Icons.mode_comment_outlined),
|
||||
setKey: SettingBoxKey.defaultShowComment,
|
||||
defaultVal: false,
|
||||
),
|
||||
ListTile(
|
||||
dense: false,
|
||||
onTap: () => settingController.seteDefaultHomePage(context),
|
||||
|
||||
@@ -56,7 +56,7 @@ class SettingPage extends StatelessWidget {
|
||||
leading: const Icon(Icons.style_outlined),
|
||||
dense: false,
|
||||
title: const Text('外观设置'),
|
||||
subtitle: Text('横屏适配(平板)、列宽、首页、主题、字号、图片、动态红点、帧率等', style: subTitleStyle),
|
||||
subtitle: Text('横屏适配(平板)、侧栏、列宽、首页、动态红点、主题、字号、图片、帧率等', style: subTitleStyle),
|
||||
),
|
||||
ListTile(
|
||||
onTap: () => Get.toNamed('/extraSetting'),
|
||||
@@ -81,7 +81,7 @@ class SettingPage extends StatelessWidget {
|
||||
visible: settingController.userLogin.value,
|
||||
child: ListTile(
|
||||
leading: const Icon(Icons.logout_outlined),
|
||||
onTap: () => settingController.loginOut(),
|
||||
onTap: () => settingController.loginOut(context),
|
||||
dense: false,
|
||||
title: const Text('退出登录'),
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user