Skip to content

Commit

Permalink
PLAYRTS-5578 Fix crash in SwiftMessages
Browse files Browse the repository at this point in the history
  • Loading branch information
mutaben committed Nov 18, 2024
1 parent 09ade52 commit 4b87c95
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions Application/Sources/Bridges/SwiftMessagesBridge.swift
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,12 @@ final class SwiftMessagesBridge: NSObject {
presentationController = presentationController?.parent
}

if let presentationController {
config.presentationContext = .viewController(presentationController)
if #available(iOS 18.0, *), UIDevice.current.userInterfaceIdiom == .pad {
config.presentationContext = .window(windowLevel: .normal)
} else {
if let presentationController {
config.presentationContext = .viewController(presentationController)
}
}

// Remark: VoiceOver is supported natively, but with the system language (not the one we might set on the
Expand Down

0 comments on commit 4b87c95

Please sign in to comment.