File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Core/Integrations/FramesTracking Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change 44#if (os(iOS) || os(tvOS) || (swift(>=5.9) && os(visionOS))) && !SENTRY_NO_UIKIT
55import UIKit
66private typealias CrossPlatformApplication = UIApplication
7- #elseif os(macOS)
7+ #elseif ( os(macOS) || targetEnvironment(macCatalyst)) && !SENTRY_NO_UIKIT
88import AppKit
99private typealias CrossPlatformApplication = NSApplication
1010#endif
Original file line number Diff line number Diff line change 33#if (os(iOS) || os(tvOS) || (swift(>=5.9) && os(visionOS))) && !SENTRY_NO_UIKIT
44import UIKit
55typealias Application = UIApplication
6- #elseif os(macOS)
6+ #elseif ( os(macOS) || targetEnvironment(macCatalyst)) && !SENTRY_NO_UIKIT
77import AppKit
88typealias Application = NSApplication
99#endif
@@ -50,7 +50,7 @@ final class SessionTracker {
5050 // WillTerminate is called no matter if started from the background or launched into the
5151 // foreground.
5252
53- #if ((os(iOS) || os(tvOS) || (swift(>=5.9) && os(visionOS))) && !SENTRY_NO_UIKIT) || os(macOS)
53+ #if ((os(iOS) || os(tvOS) || (swift(>=5.9) && os(visionOS))) && !SENTRY_NO_UIKIT) || (( os(macOS) || targetEnvironment(macCatalyst)) && !SENTRY_NO_UIKIT )
5454
5555 // Call before subscribing to the notifications to avoid that didBecomeActive gets called before
5656 // ending the cached session.
@@ -84,7 +84,7 @@ final class SessionTracker {
8484 }
8585
8686 func removeObservers( ) {
87- #if ((os(iOS) || os(tvOS) || (swift(>=5.9) && os(visionOS))) && !SENTRY_NO_UIKIT) || os(macOS)
87+ #if ((os(iOS) || os(tvOS) || (swift(>=5.9) && os(visionOS))) && !SENTRY_NO_UIKIT) || (( os(macOS) || targetEnvironment(macCatalyst)) && !SENTRY_NO_UIKIT )
8888 // Remove the observers with the most specific detail possible, see
8989 // https://developer.apple.com/documentation/foundation/nsnotificationcenter/1413994-removeobserver
9090 notificationCenter. removeObserver ( self , name: Application . didBecomeActiveNotification, object: nil )
You can’t perform that action at this time.
0 commit comments