core-location

Background tasks iPhone

坚强是说给别人听的谎言 提交于 2020-01-02 05:31:12
问题 I am trying to implement location updates in the background based on a timer. I know all about the different location updating methods in iOS and have tried them but they don't fit the need. I need to check locations every so often even while not active. I've tried using timers but they don't execute in the background. That led me to find this question How do I get a background location update every n minutes in my iOS application? and it mentions using UIApplication

Background tasks iPhone

北城以北 提交于 2020-01-02 05:31:05
问题 I am trying to implement location updates in the background based on a timer. I know all about the different location updating methods in iOS and have tried them but they don't fit the need. I need to check locations every so often even while not active. I've tried using timers but they don't execute in the background. That led me to find this question How do I get a background location update every n minutes in my iOS application? and it mentions using UIApplication

Compiler error: Invalid library file - CoreLocation

那年仲夏 提交于 2020-01-02 01:08:09
问题 I have one of my application, that is created in Xcode 8. I have used CoreLocation and MapKit in that app. I have update app with latest iOS till now. and it was working fine. Now I am updating application with iOS 1 . So I hvae opened app with Xcode 11.0 and updated all the required code. Also updated setting that is suggested by Xcode "Perform Changes" and all that. Now I run application, but I am getting error like : Compiler error: Invalid library file . I have searched lot, but can't

MKCoordinateRegion distance between center and borders

北慕城南 提交于 2020-01-01 12:31:31
问题 (Revised Question based on comment:) OK I will try to ask in other way...How can I get border coordinates of this circle overlay: (Original Question:) I am having weird problem with my iPhone app. I have MKCoordinateRegion which has center coordinate latitude: 51.509980 and longitude: -0.133700. I have used method MKCoordinateRegionMakeWithDistance and set the distance to be 16,093.44 meters (10 miles). I want to get border point of this region therefore I have this code: MKCoordinateRegion

MKCoordinateRegion distance between center and borders

徘徊边缘 提交于 2020-01-01 12:31:22
问题 (Revised Question based on comment:) OK I will try to ask in other way...How can I get border coordinates of this circle overlay: (Original Question:) I am having weird problem with my iPhone app. I have MKCoordinateRegion which has center coordinate latitude: 51.509980 and longitude: -0.133700. I have used method MKCoordinateRegionMakeWithDistance and set the distance to be 16,093.44 meters (10 miles). I want to get border point of this region therefore I have this code: MKCoordinateRegion

Save photo with geolocation data to photo library Swift 3

非 Y 不嫁゛ 提交于 2020-01-01 11:01:14
问题 How can I save a photo to photo library with geolocation metadata? I have requested (and allowed) the app to access user location: private func allowAccessToUserLocation() { locationManager = CLLocationManager() locationManager.delegate = self locationManager.requestWhenInUseAuthorization() } Do I need to ask for specific premissions for the camera app? EDIT: I use UIImagePickerController to take photos from within the app. All photos taken from within the app are stored in the photo library

CLLocation distanceFromLocation

折月煮酒 提交于 2020-01-01 03:36:05
问题 I am using CLLocation to work out the distance from the current user location, and an annotation. However I just wanted to know if this would be correct. I am currently using iPhone Simulator for this and according to the MKMapView the iPhone Simulator is situated here: Lat: 0 Long: -1067024384 The annotation's position is: workingCoordinate.latitude = 40.763856; workingCoordinate.longitude = -73.973034; However if you take a look in google maps you will find out how close these distances are

IBeacon region monitoring not work consistently across devices

走远了吗. 提交于 2020-01-01 03:22:06
问题 When testing with a simple app to test beacon region monitoring I seem to get very inconsistent results depending on the device (not the device model, the specific device). The problem is that I don't receive the CLRegionStateInside state on the region after requestStateForRegion and didEnterRegion does not get called at all on these device. startRangingBeaconsinRegion : works fine but to conserve power and processing it is recommended to only start ranging when the didEnterRegion : method

iOS Location Services visits and system Frequent Location

依然范特西╮ 提交于 2020-01-01 00:34:53
问题 I noticed that Frequent Location on iPhone seems to use much less battery than an app monitoring iOS Visits (https://developer.apple.com/reference/corelocation/clvisit). Frequent location on iPhone can be viewed on the phone via Settings -> Privacy -> Location Services -> System Services -> Frequent Locations. I would like to know if Visit monitoring service from CLLocationManager is the same as iOS Frequent location or is it on different system used by Apple. If Apple is using the same

Region monitoring current location doesn't notify on exit

你说的曾经没有我的故事 提交于 2019-12-31 13:13:09
问题 I'm trying to test region monitoring, for that I'm getting current location like this: - (void)startLocationTracking { CLLocationManager *locationManager = [[CLLocationManager alloc] init]; // Start location manager if ([CLLocationManager locationServicesEnabled] && [CLLocationManager authorizationStatus] == kCLAuthorizationStatusAuthorized) { locationManager = [LocationTracker sharedLocationManager]; locationManager.delegate = self; [locationManager startMonitoringSignificantLocationChanges]