Skip to content

Commit 6e9f9d9

Browse files
committed
no message
1 parent fbfd233 commit 6e9f9d9

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

GCPrePermissions/HJQPrePermissions/GCPrePermissions.m

+11-2
Original file line numberDiff line numberDiff line change
@@ -873,8 +873,10 @@ - (void) locationManager:(CLLocationManager *)manager didChangeAuthorizationStat
873873
- (void)showNoAutherOrRefuseAutherWithMessage:(NSString*)message
874874
{
875875
if (SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(@"9.0")) {
876-
NSURL*url=[NSURL URLWithString:UIApplicationOpenSettingsURLString];
877-
[[UIApplication sharedApplication]openURL:url];
876+
877+
UIAlertView *enterSettings = [[UIAlertView alloc]initWithTitle:@"提示" message:message delegate:self cancelButtonTitle:@"暂不" otherButtonTitles:@"设置", nil];
878+
enterSettings.tag = 100;
879+
[enterSettings show];
878880
}else{
879881

880882
UIAlertView *photoAlertviews = [[UIAlertView alloc] initWithTitle:@"提示"message:message delegate:self cancelButtonTitle:@"确定" otherButtonTitles:nil];
@@ -945,6 +947,13 @@ - (void) alertView:(UIAlertView *)alertView clickedButtonAtIndex:(NSInteger)butt
945947
// User granted access, now try to trigger the real location access
946948
// 暂且放放,等待完善GPS授权
947949
}
950+
}else if (alertView.tag == 100){
951+
if (buttonIndex == 1) {
952+
NSURL*url=[NSURL URLWithString:UIApplicationOpenSettingsURLString];
953+
[[UIApplication sharedApplication]openURL:url];
954+
}else{
955+
956+
}
948957
}
949958
}
950959

0 commit comments

Comments
 (0)