Просмотр исходного кода

update app/pages/home/maps/LocationPermission.js

wudebin 5 месяцев назад
Родитель
Сommit
10ef5a8f80
1 измененных файлов с 4 добавлено и 4 удалено
  1. 4 4
      Strides-SPAPP/app/pages/home/maps/LocationPermission.js

+ 4 - 4
Strides-SPAPP/app/pages/home/maps/LocationPermission.js

@@ -7,7 +7,7 @@ import { StyleSheet, View } from 'react-native';
 import { check, openSettings, PERMISSIONS, request, RESULTS } from 'react-native-permissions';
 import Button from '../../../components/Button';
 import TextView from '../../../components/TextView';
-import LocationEnabler from 'react-native-location-enabler';
+//import LocationEnabler from 'react-native-location-enabler';
 
 //global.hasPermission = false;
 
@@ -15,7 +15,7 @@ class LocationListener {
   constructor() {
     this.listener = undefined;
     this.config = {
-      priority: LocationEnabler.PRIORITIES.HIGH_ACCURACY, // default BALANCED_POWER_ACCURACY
+      priority: "",//LocationEnabler.PRIORITIES.HIGH_ACCURACY, // default BALANCED_POWER_ACCURACY
       alwaysShow: false, // default false
       needBle: false // default false
     };
@@ -23,7 +23,7 @@ class LocationListener {
   }
   
   addListener() {
-    this.listener = LocationEnabler?.addListener(({ locationEnabled }) => {
+    /*this.listener = LocationEnabler?.addListener(({ locationEnabled }) => {
       if (!locationEnabled) {
         console.log("status: " + this.status  + "," + locationEnabled);
         if (this.status != locationEnabled) {
@@ -31,7 +31,7 @@ class LocationListener {
           LocationEnabler.requestResolutionSettings(this.config);
         }
       }
-    })
+    })*/
   }
 
   removeListener() {