Skip to content

Commit

Permalink
Add app launcher icons.
Browse files Browse the repository at this point in the history
  • Loading branch information
fwrhine committed Nov 22, 2020
1 parent fc88342 commit 51243c1
Show file tree
Hide file tree
Showing 36 changed files with 71 additions and 82 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@drawable/ic_launcher_background"/>
<foreground android:drawable="@drawable/ic_launcher_foreground"/>
</adaptive-icon>
Binary file modified android/app/src/main/res/mipmap-hdpi/ic_launcher.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/mipmap-mdpi/ic_launcher.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/mipmap-xhdpi/ic_launcher.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/launcher/background.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/launcher/foreground.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/launcher/rainbow_icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png
109 changes: 56 additions & 53 deletions lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -96,60 +96,63 @@ class _HomeState extends State<Home> {
height: MediaQuery.of(context).size.height / 3,
width: MediaQuery.of(context).size.width,
child: Padding(
padding: EdgeInsets.only(left: 20.0, right: 20.0),
child: ListView(
children: <Widget>[
ListTile(
dense: true,
leading: Container(
width: 30,
alignment: Alignment.center,
child: FaIcon(FontAwesomeIcons.thermometerHalf),
),
title:
padding: EdgeInsets.only(left: 20.0, right: 20.0, top: 20.0),
child: MediaQuery.removePadding(
context: context,
removeTop: true,
child: ListView(
children: <Widget>[
ListTile(
dense: true,
leading: Container(
width: 30,
alignment: Alignment.center,
child: FaIcon(FontAwesomeIcons.thermometerHalf),
),
title:
Text("Temperature", style: TextStyle(fontSize: 16.0)),
trailing: Text(
temp != null
? (temp.toInt().round()).toString() + "\u00B0C"
: "",
style: TextStyle(fontSize: 16.0)),
),
ListTile(
leading: Container(
width: 30,
alignment: Alignment.center,
child: FaIcon(FontAwesomeIcons.cloud),
),
title: Text("Weather", style: TextStyle(fontSize: 16.0)),
trailing: Text(
description != null
? description.toString().capitalizeFirstofEach
: "",
style: TextStyle(fontSize: 16.0)),
),
ListTile(
leading: Container(
width: 30,
alignment: Alignment.center,
child: FaIcon(FontAwesomeIcons.sun),
),
title: Text("Humidity", style: TextStyle(fontSize: 16.0)),
trailing: Text(humidity != null ? humidity.toString() : "",
style: TextStyle(fontSize: 16.0)),
),
ListTile(
leading: Container(
width: 30,
alignment: Alignment.center,
child: FaIcon(FontAwesomeIcons.wind),
),
title: Text("Wind Speed", style: TextStyle(fontSize: 16.0)),
trailing: Text(
windSpeed != null ? windSpeed.toString() : "",
style: TextStyle(fontSize: 16.0)),
)
],
)))
trailing: Text(
temp != null
? (temp.toInt().round()).toString() + "\u00B0C"
: "",
style: TextStyle(fontSize: 16.0)),
),
ListTile(
leading: Container(
width: 30,
alignment: Alignment.center,
child: FaIcon(FontAwesomeIcons.cloud),
),
title: Text("Weather", style: TextStyle(fontSize: 16.0)),
trailing: Text(
description != null
? description.toString().capitalizeFirstofEach
: "",
style: TextStyle(fontSize: 16.0)),
),
ListTile(
leading: Container(
width: 30,
alignment: Alignment.center,
child: FaIcon(FontAwesomeIcons.sun),
),
title: Text("Humidity", style: TextStyle(fontSize: 16.0)),
trailing: Text(humidity != null ? humidity.toString() : "",
style: TextStyle(fontSize: 16.0)),
),
ListTile(
leading: Container(
width: 30,
alignment: Alignment.center,
child: FaIcon(FontAwesomeIcons.wind),
),
title: Text("Wind Speed", style: TextStyle(fontSize: 16.0)),
trailing: Text(
windSpeed != null ? windSpeed.toString() : "",
style: TextStyle(fontSize: 16.0)),
)
],
))))
]));
}
}
Expand Down
39 changes: 10 additions & 29 deletions pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ dependencies:
strings: ^0.1.4

dev_dependencies:
flutter_launcher_icons:
flutter_test:
sdk: flutter

Expand All @@ -47,33 +48,13 @@ flutter:
# the material Icons class.
uses-material-design: true

# To add assets to your application, add an assets section, like this:
# assets:
# - images/a_dot_burr.jpeg
# - images/a_dot_ham.jpeg
assets:
- assets/

# 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
# https://flutter.dev/assets-and-images/#from-packages

# To add custom fonts to your application, add a fonts section here,
# in this "flutter" section. Each entry in this list should have a
# "family" key with the font family name, and a "fonts" key with a
# list giving the asset and other descriptors for the font. For
# example:
# fonts:
# - family: Schyler
# fonts:
# - asset: fonts/Schyler-Regular.ttf
# - asset: fonts/Schyler-Italic.ttf
# style: italic
# - family: Trajan Pro
# fonts:
# - asset: fonts/TrajanPro.ttf
# - asset: fonts/TrajanPro_Bold.ttf
# weight: 700
#
# For details regarding fonts from package dependencies,
# see https://flutter.dev/custom-fonts/#from-packages
flutter_icons:
ios: true
android: true
image_path_ios: "assets/launcher/rainbow_icon.png"
image_path_android: "assets/launcher/rainbow_icon.png"
adaptive_icon_background: "assets/launcher/background.png"
adaptive_icon_foreground: "assets/launcher/foreground.png"

0 comments on commit 51243c1

Please sign in to comment.