From 05ae954b30018ff682f6d8ff1148550d12bd87d5 Mon Sep 17 00:00:00 2001 From: Yegor Vialov Date: Sun, 17 May 2020 11:16:25 +0000 Subject: [PATCH] Quick actions bar test --- lib/pages/main/main.page.dart | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/lib/pages/main/main.page.dart b/lib/pages/main/main.page.dart index a9d8075..1ac70f5 100644 --- a/lib/pages/main/main.page.dart +++ b/lib/pages/main/main.page.dart @@ -576,6 +576,7 @@ class _MainPageState extends State with WidgetsBindingObserver, Ticker SliverAppBar( floating: true, pinned: true, + snap: false, primary: true, title: Text(HomeAssistant().locationName ?? ""), actions: [ @@ -623,6 +624,31 @@ class _MainPageState extends State with WidgetsBindingObserver, Ticker _scaffoldKey.currentState.openDrawer(); }, ), + expandedHeight: 130, + flexibleSpace: FlexibleSpaceBar( + title: Padding( + padding: EdgeInsets.only(bottom: 15), + child: Row( + mainAxisSize: MainAxisSize.min, + children: [ + IconButton( + icon: Icon(Icons.add), + color: Colors.white, + onPressed: () { + Logger.d('First'); + }, + ), + IconButton( + icon: Icon(Icons.add), + color: Colors.white, + onPressed: () { + Logger.d('First'); + }, + ) + ], + ) ), + centerTitle: true, + ), bottom: empty ? null : TabBar( controller: _viewsTabController, tabs: buildUIViewTabs(),