mirror of
https://github.com/Finb/Bark.git
synced 2025-12-08 21:36:01 +00:00
修复停留在网页浏览页面时点击推送无响应的问题。
This commit is contained in:
parent
b6f31bd3dc
commit
8ae3b29bd5
@ -53,6 +53,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
|
|||||||
|
|
||||||
let navigationController = ((self.window?.rootViewController as? BarkSnackbarController)?
|
let navigationController = ((self.window?.rootViewController as? BarkSnackbarController)?
|
||||||
.rootViewController as? BarkNavigationController)
|
.rootViewController as? BarkNavigationController)
|
||||||
|
func presentController(){
|
||||||
let alert = (userInfo["aps"] as? [String:Any])?["alert"] as? [String:Any]
|
let alert = (userInfo["aps"] as? [String:Any])?["alert"] as? [String:Any]
|
||||||
let title = alert?["title"] as? String
|
let title = alert?["title"] as? String
|
||||||
let body = alert?["body"] as? String
|
let body = alert?["body"] as? String
|
||||||
@ -111,7 +112,16 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
|
|||||||
alertController.addAction(UIAlertAction(title: "取消", style: .cancel, handler: nil))
|
alertController.addAction(UIAlertAction(title: "取消", style: .cancel, handler: nil))
|
||||||
|
|
||||||
navigationController?.present(alertController, animated: true, completion: nil)
|
navigationController?.present(alertController, animated: true, completion: nil)
|
||||||
|
}
|
||||||
|
|
||||||
|
if let presentedController = navigationController?.presentedViewController {
|
||||||
|
presentedController.dismiss(animated: false) {
|
||||||
|
presentController()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
presentController()
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -17,9 +17,9 @@
|
|||||||
<key>CFBundlePackageType</key>
|
<key>CFBundlePackageType</key>
|
||||||
<string>APPL</string>
|
<string>APPL</string>
|
||||||
<key>CFBundleShortVersionString</key>
|
<key>CFBundleShortVersionString</key>
|
||||||
<string>1.0.5</string>
|
<string>1.0.6</string>
|
||||||
<key>CFBundleVersion</key>
|
<key>CFBundleVersion</key>
|
||||||
<string>3</string>
|
<string>1</string>
|
||||||
<key>LSRequiresIPhoneOS</key>
|
<key>LSRequiresIPhoneOS</key>
|
||||||
<true/>
|
<true/>
|
||||||
<key>NSAppTransportSecurity</key>
|
<key>NSAppTransportSecurity</key>
|
||||||
|
|||||||
@ -17,9 +17,9 @@
|
|||||||
<key>CFBundlePackageType</key>
|
<key>CFBundlePackageType</key>
|
||||||
<string>XPC!</string>
|
<string>XPC!</string>
|
||||||
<key>CFBundleShortVersionString</key>
|
<key>CFBundleShortVersionString</key>
|
||||||
<string>1.0.5</string>
|
<string>1.0.6</string>
|
||||||
<key>CFBundleVersion</key>
|
<key>CFBundleVersion</key>
|
||||||
<string>3</string>
|
<string>1</string>
|
||||||
<key>NSExtension</key>
|
<key>NSExtension</key>
|
||||||
<dict>
|
<dict>
|
||||||
<key>NSExtensionPointIdentifier</key>
|
<key>NSExtensionPointIdentifier</key>
|
||||||
|
|||||||
@ -17,9 +17,9 @@
|
|||||||
<key>CFBundlePackageType</key>
|
<key>CFBundlePackageType</key>
|
||||||
<string>XPC!</string>
|
<string>XPC!</string>
|
||||||
<key>CFBundleShortVersionString</key>
|
<key>CFBundleShortVersionString</key>
|
||||||
<string>1.0.5</string>
|
<string>1.0.6</string>
|
||||||
<key>CFBundleVersion</key>
|
<key>CFBundleVersion</key>
|
||||||
<string>3</string>
|
<string>1</string>
|
||||||
<key>NSExtension</key>
|
<key>NSExtension</key>
|
||||||
<dict>
|
<dict>
|
||||||
<key>NSExtensionAttributes</key>
|
<key>NSExtensionAttributes</key>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user