Я звоню CLLocationManager
, и он также вызывает его метод делегирования. Но моя проблема в том, что не обновляет свое новое местоположение после путешествия в 1 км.CLLocation Manager не обновляет новое местоположение
Вот мой код:
locationManager = [[CLLocationManager alloc] init];
locationManager.delegate = self;
locationTimer=[NSTimer scheduledTimerWithTimeInterval:1.0 target:self selector:@selector(updateLocation1:) userInfo:nil repeats:YES];
locationManager.distanceFilter = kCLDistanceFilterNone;
locationManager.desiredAccuracy = kCLLocationAccuracyBestForNavigation;
// Method did update location - Update location when location change
-(void)locationManager:(CLLocationManager *)manager didUpdateLocations:(NSArray *)locations
{
// this method is calling after every 1 sec interval time..
}
-(void)locationManager:(CLLocationManager *)manager
didUpdateToLocation:(CLLocation *)newLocation
fromLocation:(CLLocation *)oldLocation
{
// this method is not calling once also after travelling around a km ....
}
Что я делаю неправильно?