diff --git a/Platform/iOS/Settings.bundle/Root.plist b/Platform/iOS/Settings.bundle/Root.plist index 34d73baa..75619e06 100644 --- a/Platform/iOS/Settings.bundle/Root.plist +++ b/Platform/iOS/Settings.bundle/Root.plist @@ -25,6 +25,8 @@ iOS-Remote + Platform + iOS Type @@ -35,6 +37,8 @@ AutosaveBackground DefaultValue + Platform + iOS Type diff --git a/Platform/iOS/VMSessionState.swift b/Platform/iOS/VMSessionState.swift index 1924b5b9..9168b13e 100644 --- a/Platform/iOS/VMSessionState.swift +++ b/Platform/iOS/VMSessionState.swift @@ -499,6 +499,7 @@ extension VMSessionState { } func didEnterBackground() { + #if !os(visionOS) logger.info("Entering background") let shouldAutosaveBackground = UserDefaults.standard.bool(forKey: "AutosaveBackground") if shouldAutosaveBackground && vmState == .started { @@ -521,14 +522,17 @@ extension VMSessionState { task = .invalid } } + #endif } func didEnterForeground() { + #if !os(visionOS) logger.info("Entering foreground!") if (hasAutosave && vmState == .started) { logger.info("Deleting snapshot") vm.requestVmDeleteState() } + #endif } }