Resolve #382 VIew camera in chrome custom tab

This commit is contained in:
estevez-dev
2019-06-21 21:01:53 +03:00
parent caabf25260
commit 3c0ca5d16d
5 changed files with 31 additions and 24 deletions

View File

@ -153,7 +153,7 @@ class HAClientApp extends StatelessWidget {
appBar: new AppBar(
leading: IconButton(
icon: Icon(Icons.help),
onPressed: () => HAUtils.launchURLInCustomTab(context, "http://ha-client.homemade.systems/docs#authentication")
onPressed: () => HAUtils.launchURLInCustomTab(context: context, url: "http://ha-client.homemade.systems/docs#authentication")
),
title: new Text("Login to your Home Assistant"),
),
@ -548,7 +548,7 @@ class _MainPageState extends State<MainPage> with WidgetsBindingObserver, Ticker
GestureDetector(
onTap: () {
Navigator.of(context).pop();
HAUtils.launchURLInCustomTab(context, "http://ha-client.homemade.systems/terms_and_conditions");
HAUtils.launchURLInCustomTab(context: context, url: "http://ha-client.homemade.systems/terms_and_conditions");
},
child: Text(
"Terms and Conditions",
@ -564,7 +564,7 @@ class _MainPageState extends State<MainPage> with WidgetsBindingObserver, Ticker
GestureDetector(
onTap: () {
Navigator.of(context).pop();
HAUtils.launchURLInCustomTab(context, "http://ha-client.homemade.systems/privacy_policy");
HAUtils.launchURLInCustomTab(context: context, url: "http://ha-client.homemade.systems/privacy_policy");
},
child: Text(
"Privacy Policy",
@ -649,7 +649,7 @@ class _MainPageState extends State<MainPage> with WidgetsBindingObserver, Ticker
actions.add(FlatButton(
child: Text("${action.title}", style: textStyle),
onPressed: () {
HAUtils.launchURLInCustomTab(context, "${action.url}");
HAUtils.launchURLInCustomTab(context: context, url: "${action.url}");
},
));
break;