ios 打开设置页面

来源:互联网 发布:python 有抽象类吗? 编辑:程序博客网 时间:2024/05/17 04:14


- (void)jumpSysTemSettingPage{    //打开设置页面,去设置定位    NSURL *url = nil;    if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 8.0 && [CLLocationManager locationServicesEnabled])    {        url = [NSURL URLWithString:UIApplicationOpenSettingsURLString];    }        else    {        url = [NSURL URLWithString:@"prefs:root=LOCATION_SERVICES"];    }        if ([[UIApplication sharedApplication] canOpenURL:url])    {        [[UIApplication sharedApplication] openURL:url];    }}


0 0
原创粉丝点击