From a85981a93dbadd05037d50d47e546b8755d5ea91 Mon Sep 17 00:00:00 2001 From: jld3103 Date: Fri, 21 Apr 2023 13:22:22 +0200 Subject: [PATCH] neon: Fix navigation getting stuck --- packages/neon/neon/lib/src/pages/home.dart | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/neon/neon/lib/src/pages/home.dart b/packages/neon/neon/lib/src/pages/home.dart index 1153fd6c..6915eac4 100644 --- a/packages/neon/neon/lib/src/pages/home.dart +++ b/packages/neon/neon/lib/src/pages/home.dart @@ -202,15 +202,15 @@ class _HomePageState extends State { ) => OptionBuilder( option: _globalOptions.navigationMode, - builder: (final context, final navigationMode) => BackButtonListener( - onBackButtonPressed: () async { + builder: (final context, final navigationMode) => WillPopScope( + onWillPop: () async { if (_scaffoldKey.currentState!.isDrawerOpen) { Navigator.pop(context); - return false; + return true; } _scaffoldKey.currentState!.openDrawer(); - return true; + return false; }, child: Builder( builder: (final context) {