show app icon in about and links to support

This commit is contained in:
marcin_wojnarowski 2020-12-04 15:43:39 +00:00
parent 4804dc577e
commit 292654081a
2 changed files with 30 additions and 1 deletions

View File

@ -46,9 +46,37 @@ class AboutTile extends HookWidget {
FlatButton.icon(
icon: Icon(Icons.monetization_on),
label: Text('support development'),
onPressed: () {}, // TODO: link to some donation site
onPressed: () {
showDialog(
context: context,
builder: (_) => Dialog(
child: Column(
mainAxisSize: MainAxisSize.min,
children: [
FlatButton(
child: Text('Patreon'),
onPressed: () =>
openInBrowser('https://patreon.com/lemmur'),
),
FlatButton(
child: Text('Buy Me a Coffee'),
onPressed: () =>
openInBrowser('https://buymeacoff.ee/lemmur'),
),
],
),
),
);
}, // TODO: link to some donation site
),
],
applicationIcon: ClipRRect(
borderRadius: BorderRadius.circular(10),
child: Image.asset(
'assets/app_icon.png',
width: 54,
),
),
applicationVersion: packageInfo.version,
);
}

View File

@ -76,6 +76,7 @@ flutter:
# To add assets to your application, add an assets section, like this:
assets:
- CHANGELOG.md
- assets/app_icon.png
# An image asset can refer to one or more resolution-specific "variants", see
# https://flutter.dev/assets-and-images/#resolution-aware.
# For details regarding adding assets from package dependencies, see