mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-06 09:13:48 +08:00
chore: clean up
opt: pages Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
@@ -131,10 +131,8 @@ List<SettingsModel> get styleSettings => [
|
||||
onChanged: (value) {
|
||||
if (value) {
|
||||
autoScreen();
|
||||
// SmartDialog.showToast('已开启横屏适配');
|
||||
} else {
|
||||
AutoOrientation.portraitUpMode();
|
||||
// SmartDialog.showToast('已关闭横屏适配');
|
||||
}
|
||||
}),
|
||||
SettingsModel(
|
||||
@@ -536,6 +534,9 @@ List<SettingsModel> get styleSettings => [
|
||||
},
|
||||
);
|
||||
if (result != null) {
|
||||
try {
|
||||
Get.find<MineController>().themeType.value = result;
|
||||
} catch (_) {}
|
||||
GStorage.setting.put(SettingBoxKey.themeMode, result.index);
|
||||
Get.put(ColorSelectController()).themeType.value = result;
|
||||
Get.changeThemeMode(result.toThemeMode);
|
||||
|
||||
@@ -133,7 +133,7 @@ class _SetSwitchItemState extends State<SetSwitchItem> {
|
||||
: null,
|
||||
leading: widget.leading,
|
||||
trailing: Transform.scale(
|
||||
alignment: Alignment.centerRight, // 缩放Switch的大小后保持右侧对齐, 避免右侧空隙过大
|
||||
alignment: Alignment.centerRight,
|
||||
scale: 0.8,
|
||||
child: Switch(
|
||||
thumbIcon:
|
||||
@@ -141,7 +141,7 @@ class _SetSwitchItemState extends State<SetSwitchItem> {
|
||||
if (states.isNotEmpty && states.first == WidgetState.selected) {
|
||||
return const Icon(Icons.done);
|
||||
}
|
||||
return null; // All other states will use the default thumbIcon.
|
||||
return null;
|
||||
}),
|
||||
value: val,
|
||||
onChanged: switchChange,
|
||||
|
||||
Reference in New Issue
Block a user