Professional Documents
Culture Documents
1/ pubspec.yaml
add:flutter_launcher_icons: ^0.9.0
and: flutter_icons:
image_path: "assets/logo.png"
android: "launcher_icon"
ios: true
2/ tap this 2 lines in the terminal: flutter pub run
flutter pub run flutter_launcher_icons:main
#########################################################
facebook auth
terminal: $ flutter pub add flutter_facebook_login
in android/app/build.gradle add
defaultConfig {
....................
multiDexEnabled true
}
go to : https://developers.facebook.com/apps/?show_reminder=true
puis creer une app--> aucun puis nom de lapplication
facebbok login configurer suivant
map
androidmanifest.xml
rq:
To create an API key:
https://console.cloud.google.com/projectselector2/projectselector/apis/credentials?
_ga=2.5463859.1453355932.1619521842-
1563995353.1612451134&supportedpurview=project&folder=true&organizationId=true
in android/app/build.gradle add:
apply plugin: 'com.google.gms.google-services'
===========================
notification mn louta
ScaffoldMessenger.of(context).showSnackBar(
const SnackBar(content: Text('This is a snackbar')));
Alert(
context: context,
type: AlertType.error,
title: "Acident Detected",
desc: "The app has detected an accident. \n Sending SOS in $time secs.",
buttons: [
DialogButton(
child: Text(
"Send",
style: TextStyle(color: Colors.white, fontSize: 20),
),
onPressed: () { flag = 1; Navigator.pop(context);},
color: Color.fromRGBO(0, 179, 134, 1.0),
),
DialogButton(
child: Text(
"Cancel",
style: TextStyle(color: Colors.white, fontSize: 20),
),
onPressed: () { flag = 1; Navigator.pop(context);},
gradient: LinearGradient(colors: [
Color.fromRGBO(116, 116, 191, 1.0),
Color.fromRGBO(52, 138, 199, 1.0)
]),
)
],
).show();