fix license link in about

This commit is contained in:
Trent Palmer 2019-06-28 02:49:20 -07:00
parent 4d4132367e
commit f23afc98d0
3 changed files with 16 additions and 3 deletions

View File

@ -1,3 +1,4 @@
import 'package:android_intent/android_intent.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'global_helper_functions.dart'; import 'global_helper_functions.dart';
@ -24,6 +25,13 @@ InkWell aboutApp(BuildContext context) {
context: context, context: context,
builder: (BuildContext context) { builder: (BuildContext context) {
final double textHeight = 1.5; final double textHeight = 1.5;
Future<void> _launchLicense() async{
AndroidIntent intent = AndroidIntent(
action: 'action_view',
data: Uri.encodeFull('https://github.com/TrentSPalmer/libre_gps_parser/blob/master/LICENSE'),
);
await intent.launch();
}
return AlertDialog( return AlertDialog(
backgroundColor: ivory, backgroundColor: ivory,
shape: RoundedRectangleBorder( shape: RoundedRectangleBorder(
@ -44,6 +52,12 @@ InkWell aboutApp(BuildContext context) {
child: Column( child: Column(
mainAxisAlignment: MainAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.start,
children: <Widget>[ children: <Widget>[
Text(
'Version: 0.1.1\n',
style: TextStyle(
color: candyApple,
),
),
Text( Text(
'The essence of Libre Gps Parser, is to parse gps coordinates from ' 'The essence of Libre Gps Parser, is to parse gps coordinates from '
'a map link that you share from the Google Maps Application. ' 'a map link that you share from the Google Maps Application. '
@ -109,7 +123,7 @@ InkWell aboutApp(BuildContext context) {
), ),
), ),
onPressed: () { onPressed: () {
Navigator.of(context).pop(); _launchLicense();
} }
), ),
), ),

View File

@ -45,7 +45,6 @@ class _LocationState extends State<Location> {
} }
try { try {
return Row( return Row(
children: <Widget>[ children: <Widget>[
Expanded( Expanded(

View File

@ -11,7 +11,7 @@ description: A new Flutter project.
# In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion. # In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion.
# Read more about iOS versioning at # Read more about iOS versioning at
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
version: 0.1.0+4 version: 0.1.1+6
environment: environment:
sdk: ">=2.1.0 <3.0.0" sdk: ">=2.1.0 <3.0.0"