update location permission
This commit is contained in:
@ -12,6 +12,34 @@ class PermissionHandlerScreen extends StatefulWidget {
|
||||
|
||||
class _PermissionHandlerScreenState extends State<PermissionHandlerScreen> {
|
||||
|
||||
Future<void> _showMyDialog() async {
|
||||
return showDialog<void>(
|
||||
context: context,
|
||||
barrierDismissible: false, // user must tap button!
|
||||
builder: (BuildContext context) {
|
||||
return AlertDialog(
|
||||
title: const Text('ロケーション許可'),
|
||||
content: SingleChildScrollView(
|
||||
child: ListBody(
|
||||
children: const <Widget>[
|
||||
Text( 'このアプリでは、位置情報の収集を行います。'),
|
||||
Text( 'このアプリでは、開始時点で位置情報を収集します。'),
|
||||
],
|
||||
),
|
||||
),
|
||||
actions: <Widget>[
|
||||
TextButton(
|
||||
child: const Text('わかった'),
|
||||
onPressed: () {
|
||||
Navigator.of(context).pop();
|
||||
},
|
||||
),
|
||||
],
|
||||
);
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
// TODO: implement initState
|
||||
@ -33,6 +61,9 @@ class _PermissionHandlerScreenState extends State<PermissionHandlerScreen> {
|
||||
// MaterialPageRoute(builder: (context) => SplashScreen()),
|
||||
// );
|
||||
}
|
||||
else{
|
||||
_showMyDialog();
|
||||
}
|
||||
}
|
||||
},
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user