From 0e11c1a146532206fba6f51355c2d5518892c8a3 Mon Sep 17 00:00:00 2001 From: estevez Date: Mon, 24 Sep 2018 22:23:01 +0300 Subject: [PATCH] Closes #60 Hide app drawer on item tap --- lib/main.dart | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/lib/main.dart b/lib/main.dart index 7743503..202b758 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -531,20 +531,23 @@ class _MainPageState extends State with WidgetsBindingObserver { leading: Icon(Icons.settings), title: Text("Connection settings"), onTap: () { - Navigator.pushNamed(context, '/connection-settings'); + Navigator.of(context).pop(); + Navigator.of(context).pushNamed('/connection-settings'); }, ), new ListTile( leading: Icon(Icons.insert_drive_file), title: Text("Log"), onTap: () { - Navigator.pushNamed(context, '/log-view'); + Navigator.of(context).pop(); + Navigator.of(context).pushNamed('/log-view'); }, ), new ListTile( leading: Icon(MaterialDesignIcons.createIconDataFromIconName("mdi:github-circle")), title: Text("Reprot issue"), onTap: () { + Navigator.of(context).pop(); haUtils.launchURL("https://github.com/estevez-dev/ha_client_pub/issues/new"); }, ),