added ScaffoldMessenger

This commit is contained in:
Vadim 2023-05-10 14:01:17 +02:00
parent f68aea5133
commit 138e87466b

View file

@ -12,27 +12,29 @@ class SettingsScreen extends StatelessWidget {
@override
Widget build(BuildContext context) {
return SliverScreen(
title: S.of(context).settings,
appBarActions: [
IconButton(
onPressed: Navigator.of(context).pop,
icon: const Icon(Icons.close),
),
],
slivers: [
SliverList(
delegate: SliverChildListDelegate(
<Widget>[
const MeteringSettingsSection(),
const GeneralSettingsSection(),
const ThemeSettingsSection(),
const AboutSettingsSection(),
SizedBox(height: MediaQuery.of(context).padding.bottom),
],
return ScaffoldMessenger(
child: SliverScreen(
title: S.of(context).settings,
appBarActions: [
IconButton(
onPressed: Navigator.of(context).pop,
icon: const Icon(Icons.close),
),
),
],
],
slivers: [
SliverList(
delegate: SliverChildListDelegate(
<Widget>[
const MeteringSettingsSection(),
const GeneralSettingsSection(),
const ThemeSettingsSection(),
const AboutSettingsSection(),
SizedBox(height: MediaQuery.of(context).padding.bottom),
],
),
),
],
),
);
}
}