From a446359ddd5899055ab0f395f48d54c73c88a7d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Primo=C5=BE=20Ratej?= Date: Thu, 2 Feb 2023 19:55:21 +0100 Subject: [PATCH] Set Topbar to themeColor from manifest --- lib/main.dart | 7 ++----- lib/pages/web_view.dart | 13 ++++++------- 2 files changed, 8 insertions(+), 12 deletions(-) diff --git a/lib/main.dart b/lib/main.dart index ca052cb..dc6c584 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -11,12 +11,9 @@ class MyApp extends StatelessWidget { @override Widget build(BuildContext context) { - return MaterialApp( + return const MaterialApp( debugShowCheckedModeBanner: false, - theme: ThemeData( - primaryColor: const Color(0xff21A1B3), - ), - home: const Redirector(), + home: Redirector(), ); } } diff --git a/lib/pages/web_view.dart b/lib/pages/web_view.dart index a3952f8..46657ba 100644 --- a/lib/pages/web_view.dart +++ b/lib/pages/web_view.dart @@ -27,13 +27,12 @@ class WebViewAppState extends ConsumerState { @override Widget build(BuildContext context) { - return SafeArea( - child: WillPopScope( - onWillPop: () => webViewController.exitApp(context, ref), - child: Scaffold( - key: scaffoldKey, - body: WebViewWidget(controller: webViewController)), - ), + return WillPopScope( + onWillPop: () => webViewController.exitApp(context, ref), + child: Scaffold( + key: scaffoldKey, + backgroundColor: HexColor(widget.manifest.themeColor), + body: SafeArea(child: WebViewWidget(controller: webViewController))), ); } }