mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-05-20 16:18:39 +00:00
opt switch style
Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
@@ -227,17 +227,6 @@ abstract class PageUtils {
|
||||
alignment: Alignment.centerRight,
|
||||
scale: 0.8,
|
||||
child: Switch(
|
||||
thumbIcon:
|
||||
WidgetStateProperty.resolveWith<Icon?>((
|
||||
Set<WidgetState> states,
|
||||
) {
|
||||
if (states.isNotEmpty &&
|
||||
states.first ==
|
||||
WidgetState.selected) {
|
||||
return const Icon(Icons.done);
|
||||
}
|
||||
return null;
|
||||
}),
|
||||
value: shutdownTimerService
|
||||
.waitForPlayingCompleted,
|
||||
onChanged: (value) {
|
||||
|
||||
@@ -115,6 +115,14 @@ abstract class ThemeUtils {
|
||||
cupertinoOverrideTheme: CupertinoThemeData(
|
||||
selectionHandleColor: colorScheme.primary,
|
||||
),
|
||||
switchTheme: const SwitchThemeData(
|
||||
thumbIcon: WidgetStateProperty<Icon?>.fromMap(
|
||||
<WidgetStatesConstraint, Icon?>{
|
||||
WidgetState.selected: Icon(Icons.done),
|
||||
WidgetState.any: null,
|
||||
},
|
||||
),
|
||||
),
|
||||
);
|
||||
if (isDark) {
|
||||
if (Pref.isPureBlackTheme) {
|
||||
|
||||
Reference in New Issue
Block a user