swift 跳转到系统设置/网络/推送提醒

使用App-Prefs做域跳转,代码如下:

if let url = URL(string: "App-Prefs:root=NOTIFICATIONS_ID"), UIApplication.shared.canOpenURL(url) {
  UIApplication.shared.open(url, options: [:], completionHandler: nil)
}

 

类似的域还有:

App-Prefs:root=WIFI
App-Prefs:root=Bluetooth
App-Prefs:root=MOBILE_DATA_SETTINGS_ID
App-Prefs:root=INTERNET_TETHERING
App-Prefs:root=Carrier
App-Prefs:root=NOTIFICATIONS_ID
App-Prefs:root=General
App-Prefs:root=General&path=About
App-Prefs:root=General&path=Keyboard
App-Prefs:root=Wallpaper
App-Prefs:root=SIRI
App-Prefs:root=Privacy
App-Prefs:root=SAFARI
App-Prefs:root=MUSIC
App-Prefs:root=MUSIC&path=com.apple.Music:EQ
App-Prefs:root=Photos

 

posted @ 2019-07-31 13:30  woodchuckkk  阅读(1431)  评论(0编辑  收藏  举报