mirror of
https://github.com/HendrikRauh/inventree-app.git
synced 2026-04-17 16:10:34 +00:00
Update flutter version (#805)
* Update flutter version - 3.32.4 to 3.41.6 (stable) * Update version and release notes * Update to modern API
This commit is contained in:
parent
83e97c56a2
commit
4d415c8fa2
7 changed files with 65 additions and 78 deletions
|
|
@ -35,50 +35,33 @@ class ThemeSelectionDialog extends StatelessWidget {
|
|||
content: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
RadioListTile<AdaptiveThemeMode>(
|
||||
title: Row(
|
||||
children: [
|
||||
Icon(TablerIcons.device_desktop),
|
||||
SizedBox(width: 10),
|
||||
Text("System"),
|
||||
],
|
||||
),
|
||||
value: AdaptiveThemeMode.system,
|
||||
RadioGroup<AdaptiveThemeMode>(
|
||||
groupValue: currentThemeMode,
|
||||
onChanged: (value) {
|
||||
AdaptiveTheme.of(context).setThemeMode(AdaptiveThemeMode.system);
|
||||
onThemeSelected();
|
||||
if (value != null) {
|
||||
AdaptiveTheme.of(context).setThemeMode(value);
|
||||
onThemeSelected();
|
||||
}
|
||||
},
|
||||
),
|
||||
RadioListTile<AdaptiveThemeMode>(
|
||||
title: Row(
|
||||
child: Column(
|
||||
children: [
|
||||
Icon(TablerIcons.sun),
|
||||
SizedBox(width: 10),
|
||||
Text("Light"),
|
||||
RadioListTile<AdaptiveThemeMode>(
|
||||
value: AdaptiveThemeMode.system,
|
||||
title: Text(L10().system),
|
||||
secondary: Icon(TablerIcons.device_desktop),
|
||||
),
|
||||
RadioListTile<AdaptiveThemeMode>(
|
||||
value: AdaptiveThemeMode.light,
|
||||
title: Text(L10().lightMode),
|
||||
secondary: Icon(TablerIcons.sun),
|
||||
),
|
||||
RadioListTile<AdaptiveThemeMode>(
|
||||
value: AdaptiveThemeMode.dark,
|
||||
title: Text(L10().darkMode),
|
||||
secondary: Icon(TablerIcons.moon),
|
||||
),
|
||||
],
|
||||
),
|
||||
value: AdaptiveThemeMode.light,
|
||||
groupValue: currentThemeMode,
|
||||
onChanged: (value) {
|
||||
AdaptiveTheme.of(context).setThemeMode(AdaptiveThemeMode.light);
|
||||
onThemeSelected();
|
||||
},
|
||||
),
|
||||
RadioListTile<AdaptiveThemeMode>(
|
||||
title: Row(
|
||||
children: [
|
||||
Icon(TablerIcons.moon),
|
||||
SizedBox(width: 10),
|
||||
Text("Dark"),
|
||||
],
|
||||
),
|
||||
value: AdaptiveThemeMode.dark,
|
||||
groupValue: currentThemeMode,
|
||||
onChanged: (value) {
|
||||
AdaptiveTheme.of(context).setThemeMode(AdaptiveThemeMode.dark);
|
||||
onThemeSelected();
|
||||
},
|
||||
),
|
||||
],
|
||||
),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue