UIWindowSceneDelegate
Additional methods that you use to manage app-specific tasks occurring in a scene.
Declaration
@MainActor protocol UIWindowSceneDelegate : UISceneDelegateMentioned in
Overview
Use your UIWindowSceneDelegate object to manage the life cycle of one instance of your app’s user interface. The window scene delegate conforms to the UISceneDelegate protocol, and you use it to receive notifications when its scene connects to the app, enters the foreground, and so on. You also use it to respond to changes in the underlying environment of the scene. For example, if the user resizes a scene, use your delegate to make any needed changes to your content to accommodate the new size.
Don’t create UIWindowSceneDelegate objects directly. Instead, specify the name of your delegate class as part of the configuration data for your scene. You can specify this information in your app’s Info.plist file, or in the UISceneConfiguration object you return from your app delegate’s application(_:configurationForConnecting:options:) method. For more information about how to configure scenes, see Specifying the scenes your app supports.
For an example on using UIWindowSceneDelegate in your app, see Supporting multiple windows on iPad.