diff options
author | Scott Murray <scott.murray@konsulko.com> | 2024-01-23 15:51:45 -0500 |
---|---|---|
committer | Scott Murray <scott.murray@konsulko.com> | 2024-01-23 16:40:09 -0500 |
commit | cc99d4d772be6635639a0d398076a8890f4e6a42 (patch) | |
tree | db3b41545c94337b43421bab00b829181fdbf57d /lib/presentation/screens/home/home.dart | |
parent | ee592b5048543951f712c0abb997a6e97c036544 (diff) |
Connect audio settings button
Rework to connect the audio settings button on the media pages
to the appropriate settings page, and have the back button go
back to the expected previous page. To enable this, the global
AppState provider was reworked to track the previous page and add
explicit update and back member functions.
Bug-AGL: SPEC-5030
Change-Id: I5858d1b1bf511a184b6538b2ce8c183b00c24fc6
Signed-off-by: Scott Murray <scott.murray@konsulko.com>
Diffstat (limited to 'lib/presentation/screens/home/home.dart')
-rw-r--r-- | lib/presentation/screens/home/home.dart | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/presentation/screens/home/home.dart b/lib/presentation/screens/home/home.dart index 3d80f92..8f0d125 100644 --- a/lib/presentation/screens/home/home.dart +++ b/lib/presentation/screens/home/home.dart @@ -28,7 +28,7 @@ class HomeScreenState extends ConsumerState<HomeScreen> { BuildContext context, ) { return Consumer(builder: (context, ref, child) { - final state = ref.read(appProvider); + final appState = ref.watch(appProvider); final bool disableBkgAnimation = ref.read(appConfigProvider).disableBkgAnimation; if (disableBkgAnimation) { @@ -48,13 +48,13 @@ class HomeScreenState extends ConsumerState<HomeScreen> { repeat: true, ), FlowBuilder<AppState>( - state: ref.watch(appProvider), + state: appState, onGeneratePages: onGenerateAppViewPages, observers: [ HeroController(), ], ), - if (state != AppState.splash) + if (appState != AppState.splash) Positioned( top: 0, bottom: 0, @@ -66,7 +66,7 @@ class HomeScreenState extends ConsumerState<HomeScreen> { ], ), bottomNavigationBar: - state == AppState.splash ? null : const CustomBottomBar(), + appState == AppState.splash ? null : const CustomBottomBar(), ); }); } |