[英]CLLocationManager delegate not called
我正在使用iBeacons,但遇到了一個小問題。
首次使用時,用戶需要授予權限,然后我們將其稱為:
_locationManager = [[CLLocationManager alloc] init];
_locationManager.delegate = self;
[_locationManager requestAlwaysAuthorization];
但是,我希望調用以下委托方法:
- (void)locationManager:(CLLocationManager *)manager didChangeAuthorizationStatus:(CLAuthorizationStatus)status {
NSLog(@"Auth status changed: %i", status);
if(status > 3){
// Check if we have to start monitoring beacons
NSLog(@"Do we need to initialise after auth given?");
//[self initialiseLocations];
}
}
我正在運行iOS 8.0.2,所以不確定是否是錯誤
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.