Change RadioListTile radius

This commit is contained in:
stonegate 2020-07-12 20:53:34 +08:00
parent 6a88054ffe
commit 1710e5da77
1 changed files with 45 additions and 24 deletions

View File

@ -82,30 +82,51 @@ class ThemeSetting extends StatelessWidget {
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
children: <Widget>[
RadioListTile(
title: Text(s.systemDefault),
value: ThemeMode.system,
groupValue: settings.theme,
onChanged: (value) {
settings.setTheme = value;
Navigator.of(context).pop();
}),
RadioListTile(
title: Text(s.darkMode),
value: ThemeMode.dark,
groupValue: settings.theme,
onChanged: (value) {
settings.setTheme = value;
Navigator.of(context).pop();
}),
RadioListTile(
title: Text(s.lightMode),
value: ThemeMode.light,
groupValue: settings.theme,
onChanged: (value) {
settings.setTheme = value;
Navigator.of(context).pop();
}),
ClipRRect(
borderRadius:
BorderRadius.all(Radius.circular(5)),
child: Material(
color: Colors.transparent,
child: RadioListTile(
title: Text(s.systemDefault),
value: ThemeMode.system,
groupValue: settings.theme,
onChanged: (value) {
settings.setTheme = value;
Navigator.of(context).pop();
}),
),
),
ClipRRect(
borderRadius:
BorderRadius.all(Radius.circular(5)),
child: Material(
color: Colors.transparent,
child: RadioListTile(
title: Text(s.darkMode),
value: ThemeMode.dark,
groupValue: settings.theme,
onChanged: (value) {
settings.setTheme = value;
Navigator.of(context).pop();
}),
),
),
ClipRRect(
borderRadius:
BorderRadius.all(Radius.circular(5)),
child: Material(
color: Colors.transparent,
child: RadioListTile(
title: Text(s.lightMode),
value: ThemeMode.light,
groupValue: settings.theme,
onChanged: (value) {
settings.setTheme = value;
Navigator.of(context).pop();
}),
),
),
],
),
),