Commit 522615568737ea273d71ed71f792da16946c741a

Authored by wdn127929
1 parent 3be2694a

地图页闪退&&拍照黑屏几秒

... ... @@ -31,6 +31,7 @@
android:icon="@mipmap/ic_launcher"
android:requestLegacyExternalStorage="true"
android:preserveLegacyExternalStorage="true"
android:allowNativeHeapPointerTagging="false"
>
<activity
... ...
... ... @@ -68,7 +68,17 @@ class _MapChoicePointPageState extends State<MapChoicePointPage> {
_requestLocationPermission() async {
await AmapLocation.instance.updatePrivacyShow(true);
await AmapLocation.instance.updatePrivacyAgree(true);
bool canLocation = await requestPermission(Permission.location);
bool canLocation = false;
if (!(await checkPermission(Permission.location))) {
//没有定位权限
//申请定位权限
canLocation = await requestPermission(Permission.location);
} else {
canLocation = true;
}
// bool canLocation = await requestPermission(Permission.location);
// 单次定位
if (canLocation) {
Future.delayed(Duration(milliseconds: 200), () async {
... ...
... ... @@ -233,11 +233,11 @@ class DialogUtil {
static showAuthorityDestination(
BuildContext context, String name, String title, String subTitle) async {
// Timer _timer = Timer(const Duration(seconds: 2), () {
// // if(!TickerMode.of(context)){
// Navigator.of(context).pop(true);
// // }
// });
Timer _timer = Timer(const Duration(seconds: 2), () {
// if(!TickerMode.of(context)){
Navigator.of(context).pop(true);
// }
});
final action = await showDialog(
context: context,
barrierDismissible: true,
... ... @@ -288,7 +288,7 @@ class DialogUtil {
});
print(action);
// _timer.cancel();
_timer.cancel();
return action;
}
... ...
... ... @@ -14,28 +14,28 @@ packages:
name: amap_core_fluttify
url: "https://pub.flutter-io.cn"
source: hosted
version: "0.17.0-rc.0"
version: "0.17.0"
amap_location_fluttify:
dependency: transitive
description:
name: amap_location_fluttify
url: "https://pub.flutter-io.cn"
source: hosted
version: "0.22.0-rc.0"
version: "0.22.0"
amap_map_fluttify:
dependency: "direct main"
description:
name: amap_map_fluttify
url: "https://pub.flutter-io.cn"
source: hosted
version: "2.0.0-rc.1"
version: "2.0.2"
amap_search_fluttify:
dependency: transitive
description:
name: amap_search_fluttify
url: "https://pub.flutter-io.cn"
source: hosted
version: "0.18.0-rc.0"
version: "0.18.0"
analyzer:
dependency: transitive
description:
... ... @@ -329,7 +329,7 @@ packages:
name: core_location_fluttify
url: "https://pub.flutter-io.cn"
source: hosted
version: "0.7.0-rc.0"
version: "0.7.1"
cross_file:
dependency: transitive
description:
... ... @@ -713,7 +713,7 @@ packages:
name: foundation_fluttify
url: "https://pub.flutter-io.cn"
source: hosted
version: "0.13.0-rc.0"
version: "0.13.0+1"
frontend_server_client:
dependency: transitive
description:
... ... @@ -1455,7 +1455,7 @@ packages:
name: url_launcher
url: "https://pub.flutter-io.cn"
source: hosted
version: "6.1.2"
version: "6.1.11"
url_launcher_android:
dependency: transitive
description:
... ... @@ -1490,7 +1490,7 @@ packages:
name: url_launcher_platform_interface
url: "https://pub.flutter-io.cn"
source: hosted
version: "2.0.5"
version: "2.1.3"
url_launcher_web:
dependency: transitive
description:
... ...
... ... @@ -168,7 +168,7 @@ dependencies:
video_compress: ^3.1.1
#高德地图
# amap_map_fluttify: 0.25.0
amap_map_fluttify: ^2.0.0-rc.1
amap_map_fluttify: ^2.0.2
#虚线边框
dotted_border: ^1.0.7
... ...