pub unsafe trait UIApplicationDelegate: NSObjectProtocol + MainThreadOnly {
Show 53 methods
// Provided methods
fn applicationDidFinishLaunching(&self, application: &UIApplication)
where Self: Sized + Message { ... }
unsafe fn application_willFinishLaunchingWithOptions(
&self,
application: &UIApplication,
launch_options: Option<&NSDictionary<UIApplicationLaunchOptionsKey, AnyObject>>,
) -> bool
where Self: Sized + Message { ... }
unsafe fn application_didFinishLaunchingWithOptions(
&self,
application: &UIApplication,
launch_options: Option<&NSDictionary<UIApplicationLaunchOptionsKey, AnyObject>>,
) -> bool
where Self: Sized + Message { ... }
fn applicationDidBecomeActive(&self, application: &UIApplication)
where Self: Sized + Message { ... }
fn applicationWillResignActive(&self, application: &UIApplication)
where Self: Sized + Message { ... }
fn applicationDidEnterBackground(&self, application: &UIApplication)
where Self: Sized + Message { ... }
fn applicationWillEnterForeground(&self, application: &UIApplication)
where Self: Sized + Message { ... }
fn application_handleOpenURL(
&self,
application: &UIApplication,
url: &NSURL,
) -> bool
where Self: Sized + Message { ... }
unsafe fn application_openURL_sourceApplication_annotation(
&self,
application: &UIApplication,
url: &NSURL,
source_application: Option<&NSString>,
annotation: &AnyObject,
) -> bool
where Self: Sized + Message { ... }
unsafe fn application_openURL_options(
&self,
app: &UIApplication,
url: &NSURL,
options: &NSDictionary<UIApplicationOpenURLOptionsKey, AnyObject>,
) -> bool
where Self: Sized + Message { ... }
fn applicationDidReceiveMemoryWarning(&self, application: &UIApplication)
where Self: Sized + Message { ... }
fn applicationWillTerminate(&self, application: &UIApplication)
where Self: Sized + Message { ... }
fn applicationSignificantTimeChange(&self, application: &UIApplication)
where Self: Sized + Message { ... }
fn application_willChangeStatusBarOrientation_duration(
&self,
application: &UIApplication,
new_status_bar_orientation: UIInterfaceOrientation,
duration: NSTimeInterval,
)
where Self: Sized + Message { ... }
fn application_didChangeStatusBarOrientation(
&self,
application: &UIApplication,
old_status_bar_orientation: UIInterfaceOrientation,
)
where Self: Sized + Message { ... }
fn application_willChangeStatusBarFrame(
&self,
application: &UIApplication,
new_status_bar_frame: CGRect,
)
where Self: Sized + Message { ... }
fn application_didChangeStatusBarFrame(
&self,
application: &UIApplication,
old_status_bar_frame: CGRect,
)
where Self: Sized + Message { ... }
fn application_didRegisterUserNotificationSettings(
&self,
application: &UIApplication,
notification_settings: &UIUserNotificationSettings,
)
where Self: Sized + Message { ... }
fn application_didRegisterForRemoteNotificationsWithDeviceToken(
&self,
application: &UIApplication,
device_token: &NSData,
)
where Self: Sized + Message { ... }
fn application_didFailToRegisterForRemoteNotificationsWithError(
&self,
application: &UIApplication,
error: &NSError,
)
where Self: Sized + Message { ... }
unsafe fn application_didReceiveRemoteNotification(
&self,
application: &UIApplication,
user_info: &NSDictionary,
)
where Self: Sized + Message { ... }
fn application_didReceiveLocalNotification(
&self,
application: &UIApplication,
notification: &UILocalNotification,
)
where Self: Sized + Message { ... }
fn application_handleActionWithIdentifier_forLocalNotification_completionHandler(
&self,
application: &UIApplication,
identifier: Option<&NSString>,
notification: &UILocalNotification,
completion_handler: &DynBlock<dyn Fn()>,
)
where Self: Sized + Message { ... }
unsafe fn application_handleActionWithIdentifier_forRemoteNotification_withResponseInfo_completionHandler(
&self,
application: &UIApplication,
identifier: Option<&NSString>,
user_info: &NSDictionary,
response_info: &NSDictionary,
completion_handler: &DynBlock<dyn Fn()>,
)
where Self: Sized + Message { ... }
unsafe fn application_handleActionWithIdentifier_forRemoteNotification_completionHandler(
&self,
application: &UIApplication,
identifier: Option<&NSString>,
user_info: &NSDictionary,
completion_handler: &DynBlock<dyn Fn()>,
)
where Self: Sized + Message { ... }
unsafe fn application_handleActionWithIdentifier_forLocalNotification_withResponseInfo_completionHandler(
&self,
application: &UIApplication,
identifier: Option<&NSString>,
notification: &UILocalNotification,
response_info: &NSDictionary,
completion_handler: &DynBlock<dyn Fn()>,
)
where Self: Sized + Message { ... }
unsafe fn application_didReceiveRemoteNotification_fetchCompletionHandler(
&self,
application: &UIApplication,
user_info: &NSDictionary,
completion_handler: &DynBlock<dyn Fn(UIBackgroundFetchResult)>,
)
where Self: Sized + Message { ... }
fn application_performFetchWithCompletionHandler(
&self,
application: &UIApplication,
completion_handler: &DynBlock<dyn Fn(UIBackgroundFetchResult)>,
)
where Self: Sized + Message { ... }
fn application_performActionForShortcutItem_completionHandler(
&self,
application: &UIApplication,
shortcut_item: &UIApplicationShortcutItem,
completion_handler: &DynBlock<dyn Fn(Bool)>,
)
where Self: Sized + Message { ... }
fn application_handleEventsForBackgroundURLSession_completionHandler(
&self,
application: &UIApplication,
identifier: &NSString,
completion_handler: &DynBlock<dyn Fn()>,
)
where Self: Sized + Message { ... }
unsafe fn application_handleWatchKitExtensionRequest_reply(
&self,
application: &UIApplication,
user_info: Option<&NSDictionary>,
reply: &DynBlock<dyn Fn(*mut NSDictionary)>,
)
where Self: Sized + Message { ... }
fn applicationShouldRequestHealthAuthorization(
&self,
application: &UIApplication,
)
where Self: Sized + Message { ... }
fn applicationProtectedDataWillBecomeUnavailable(
&self,
application: &UIApplication,
)
where Self: Sized + Message { ... }
fn applicationProtectedDataDidBecomeAvailable(
&self,
application: &UIApplication,
)
where Self: Sized + Message { ... }
fn window(&self) -> Option<Retained<UIWindow>>
where Self: Sized + Message { ... }
fn setWindow(&self, window: Option<&UIWindow>)
where Self: Sized + Message { ... }
fn application_supportedInterfaceOrientationsForWindow(
&self,
application: &UIApplication,
window: Option<&UIWindow>,
) -> UIInterfaceOrientationMask
where Self: Sized + Message { ... }
fn application_shouldAllowExtensionPointIdentifier(
&self,
application: &UIApplication,
extension_point_identifier: &UIApplicationExtensionPointIdentifier,
) -> bool
where Self: Sized + Message { ... }
unsafe fn application_viewControllerWithRestorationIdentifierPath_coder(
&self,
application: &UIApplication,
identifier_components: &NSArray<NSString>,
coder: &NSCoder,
) -> Option<Retained<UIViewController>>
where Self: Sized + Message { ... }
unsafe fn application_shouldSaveSecureApplicationState(
&self,
application: &UIApplication,
coder: &NSCoder,
) -> bool
where Self: Sized + Message { ... }
unsafe fn application_shouldRestoreSecureApplicationState(
&self,
application: &UIApplication,
coder: &NSCoder,
) -> bool
where Self: Sized + Message { ... }
unsafe fn application_willEncodeRestorableStateWithCoder(
&self,
application: &UIApplication,
coder: &NSCoder,
)
where Self: Sized + Message { ... }
unsafe fn application_didDecodeRestorableStateWithCoder(
&self,
application: &UIApplication,
coder: &NSCoder,
)
where Self: Sized + Message { ... }
unsafe fn application_shouldSaveApplicationState(
&self,
application: &UIApplication,
coder: &NSCoder,
) -> bool
where Self: Sized + Message { ... }
unsafe fn application_shouldRestoreApplicationState(
&self,
application: &UIApplication,
coder: &NSCoder,
) -> bool
where Self: Sized + Message { ... }
fn application_willContinueUserActivityWithType(
&self,
application: &UIApplication,
user_activity_type: &NSString,
) -> bool
where Self: Sized + Message { ... }
fn application_continueUserActivity_restorationHandler(
&self,
application: &UIApplication,
user_activity: &NSUserActivity,
restoration_handler: &DynBlock<dyn Fn(*mut NSArray<ProtocolObject<dyn UIUserActivityRestoring>>)>,
) -> bool
where Self: Sized + Message { ... }
fn application_didFailToContinueUserActivityWithType_error(
&self,
application: &UIApplication,
user_activity_type: &NSString,
error: &NSError,
)
where Self: Sized + Message { ... }
fn application_didUpdateUserActivity(
&self,
application: &UIApplication,
user_activity: &NSUserActivity,
)
where Self: Sized + Message { ... }
fn application_userDidAcceptCloudKitShareWithMetadata(
&self,
application: &UIApplication,
cloud_kit_share_metadata: &CKShareMetadata,
)
where Self: Sized + Message { ... }
fn application_configurationForConnectingSceneSession_options(
&self,
application: &UIApplication,
connecting_scene_session: &UISceneSession,
options: &UISceneConnectionOptions,
) -> Retained<UISceneConfiguration>
where Self: Sized + Message { ... }
fn application_didDiscardSceneSessions(
&self,
application: &UIApplication,
scene_sessions: &NSSet<UISceneSession>,
)
where Self: Sized + Message { ... }
fn applicationShouldAutomaticallyLocalizeKeyCommands(
&self,
application: &UIApplication,
) -> bool
where Self: Sized + Message { ... }
}UIApplication only.Expand description
Provided Methods§
fn applicationDidFinishLaunching(&self, application: &UIApplication)
UIResponder only.Sourceunsafe fn application_willFinishLaunchingWithOptions(
&self,
application: &UIApplication,
launch_options: Option<&NSDictionary<UIApplicationLaunchOptionsKey, AnyObject>>,
) -> bool
Available on crate feature UIResponder only.
unsafe fn application_willFinishLaunchingWithOptions( &self, application: &UIApplication, launch_options: Option<&NSDictionary<UIApplicationLaunchOptionsKey, AnyObject>>, ) -> bool
UIResponder only.§Safety
launch_options generic should be of the correct type.
Sourceunsafe fn application_didFinishLaunchingWithOptions(
&self,
application: &UIApplication,
launch_options: Option<&NSDictionary<UIApplicationLaunchOptionsKey, AnyObject>>,
) -> bool
Available on crate feature UIResponder only.
unsafe fn application_didFinishLaunchingWithOptions( &self, application: &UIApplication, launch_options: Option<&NSDictionary<UIApplicationLaunchOptionsKey, AnyObject>>, ) -> bool
UIResponder only.§Safety
launch_options generic should be of the correct type.
Sourcefn applicationDidBecomeActive(&self, application: &UIApplication)
👎Deprecated: Use UIScene lifecycle and sceneDidBecomeActive(_:) from UISceneDelegate or the UIApplication.didBecomeActiveNotification instead.Available on crate feature UIResponder only.
fn applicationDidBecomeActive(&self, application: &UIApplication)
UIResponder only.Tells the delegate that the application has become active
- Note: This method is not called if
UIScenelifecycle has been adopted.
Sourcefn applicationWillResignActive(&self, application: &UIApplication)
👎Deprecated: Use UIScene lifecycle and sceneWillResignActive(_:) from UISceneDelegate or the UIApplication.willResignActiveNotification instead.Available on crate feature UIResponder only.
fn applicationWillResignActive(&self, application: &UIApplication)
UIResponder only.Tells the delegate that the application is about to become inactive
- Note: This method is not called if
UIScenelifecycle has been adopted.
Sourcefn applicationDidEnterBackground(&self, application: &UIApplication)
👎Deprecated: Use UIScene lifecycle and sceneDidEnterBackground(_:) from UISceneDelegate or the UIApplication.didEnterBackgroundNotification instead.Available on crate feature UIResponder only.
fn applicationDidEnterBackground(&self, application: &UIApplication)
UIResponder only.Tells the delegate that the application is now in the background
- Note: This method is not called if
UIScenelifecycle has been adopted.
Sourcefn applicationWillEnterForeground(&self, application: &UIApplication)
👎Deprecated: Use UIScene lifecycle and sceneWillEnterForeground(_:) from UISceneDelegate or the UIApplication.willEnterForegroundNotification instead.Available on crate feature UIResponder only.
fn applicationWillEnterForeground(&self, application: &UIApplication)
UIResponder only.Tells the delegate that the application is about to enter the foreground
- Note: This method is not called if
UIScenelifecycle has been adopted.
fn application_handleOpenURL( &self, application: &UIApplication, url: &NSURL, ) -> bool
UIResponder only.Sourceunsafe fn application_openURL_sourceApplication_annotation(
&self,
application: &UIApplication,
url: &NSURL,
source_application: Option<&NSString>,
annotation: &AnyObject,
) -> bool
👎DeprecatedAvailable on crate feature UIResponder only.
unsafe fn application_openURL_sourceApplication_annotation( &self, application: &UIApplication, url: &NSURL, source_application: Option<&NSString>, annotation: &AnyObject, ) -> bool
UIResponder only.§Safety
annotation should be of the correct type.
Sourceunsafe fn application_openURL_options(
&self,
app: &UIApplication,
url: &NSURL,
options: &NSDictionary<UIApplicationOpenURLOptionsKey, AnyObject>,
) -> bool
👎Deprecated: Use UIScene lifecycle and scene(_:openURLContexts:) from UISceneDelegate instead.Available on crate feature UIResponder only.
unsafe fn application_openURL_options( &self, app: &UIApplication, url: &NSURL, options: &NSDictionary<UIApplicationOpenURLOptionsKey, AnyObject>, ) -> bool
UIResponder only.Return NO if the application can’t open the url for some reason
§Safety
options generic should be of the correct type.
fn applicationDidReceiveMemoryWarning(&self, application: &UIApplication)
UIResponder only.fn applicationWillTerminate(&self, application: &UIApplication)
UIResponder only.fn applicationSignificantTimeChange(&self, application: &UIApplication)
UIResponder only.fn application_willChangeStatusBarOrientation_duration( &self, application: &UIApplication, new_status_bar_orientation: UIInterfaceOrientation, duration: NSTimeInterval, )
UIOrientation and UIResponder only.fn application_didChangeStatusBarOrientation( &self, application: &UIApplication, old_status_bar_orientation: UIInterfaceOrientation, )
UIOrientation and UIResponder only.fn application_willChangeStatusBarFrame( &self, application: &UIApplication, new_status_bar_frame: CGRect, )
UIResponder and objc2-core-foundation only.fn application_didChangeStatusBarFrame( &self, application: &UIApplication, old_status_bar_frame: CGRect, )
UIResponder and objc2-core-foundation only.fn application_didRegisterUserNotificationSettings( &self, application: &UIApplication, notification_settings: &UIUserNotificationSettings, )
UIResponder and UIUserNotificationSettings only.fn application_didRegisterForRemoteNotificationsWithDeviceToken( &self, application: &UIApplication, device_token: &NSData, )
UIResponder only.fn application_didFailToRegisterForRemoteNotificationsWithError( &self, application: &UIApplication, error: &NSError, )
UIResponder only.Sourceunsafe fn application_didReceiveRemoteNotification(
&self,
application: &UIApplication,
user_info: &NSDictionary,
)
👎Deprecated: Use UserNotifications Framework’s -[UNUserNotificationCenterDelegate willPresentNotification:withCompletionHandler:] or -[UNUserNotificationCenterDelegate didReceiveNotificationResponse:withCompletionHandler:] for user visible notifications and -[UIApplicationDelegate application:didReceiveRemoteNotification:fetchCompletionHandler:] for silent remote notificationsAvailable on crate feature UIResponder only.
unsafe fn application_didReceiveRemoteNotification( &self, application: &UIApplication, user_info: &NSDictionary, )
UIResponder only.§Safety
user_info generic should be of the correct type.
fn application_didReceiveLocalNotification( &self, application: &UIApplication, notification: &UILocalNotification, )
UILocalNotification and UIResponder only.fn application_handleActionWithIdentifier_forLocalNotification_completionHandler( &self, application: &UIApplication, identifier: Option<&NSString>, notification: &UILocalNotification, completion_handler: &DynBlock<dyn Fn()>, )
UILocalNotification and UIResponder and block2 only.Sourceunsafe fn application_handleActionWithIdentifier_forRemoteNotification_withResponseInfo_completionHandler(
&self,
application: &UIApplication,
identifier: Option<&NSString>,
user_info: &NSDictionary,
response_info: &NSDictionary,
completion_handler: &DynBlock<dyn Fn()>,
)
👎Deprecated: Use UserNotifications Framework’s -[UNUserNotificationCenterDelegate didReceiveNotificationResponse:withCompletionHandler:]Available on crate features UIResponder and block2 only.
unsafe fn application_handleActionWithIdentifier_forRemoteNotification_withResponseInfo_completionHandler( &self, application: &UIApplication, identifier: Option<&NSString>, user_info: &NSDictionary, response_info: &NSDictionary, completion_handler: &DynBlock<dyn Fn()>, )
UIResponder and block2 only.§Safety
user_infogeneric should be of the correct type.response_infogeneric should be of the correct type.
Sourceunsafe fn application_handleActionWithIdentifier_forRemoteNotification_completionHandler(
&self,
application: &UIApplication,
identifier: Option<&NSString>,
user_info: &NSDictionary,
completion_handler: &DynBlock<dyn Fn()>,
)
👎Deprecated: Use UserNotifications Framework’s -[UNUserNotificationCenterDelegate didReceiveNotificationResponse:withCompletionHandler:]Available on crate features UIResponder and block2 only.
unsafe fn application_handleActionWithIdentifier_forRemoteNotification_completionHandler( &self, application: &UIApplication, identifier: Option<&NSString>, user_info: &NSDictionary, completion_handler: &DynBlock<dyn Fn()>, )
UIResponder and block2 only.§Safety
user_info generic should be of the correct type.
Sourceunsafe fn application_handleActionWithIdentifier_forLocalNotification_withResponseInfo_completionHandler(
&self,
application: &UIApplication,
identifier: Option<&NSString>,
notification: &UILocalNotification,
response_info: &NSDictionary,
completion_handler: &DynBlock<dyn Fn()>,
)
👎Deprecated: Use UserNotifications Framework’s -[UNUserNotificationCenterDelegate didReceiveNotificationResponse:withCompletionHandler:]Available on crate features UILocalNotification and UIResponder and block2 only.
unsafe fn application_handleActionWithIdentifier_forLocalNotification_withResponseInfo_completionHandler( &self, application: &UIApplication, identifier: Option<&NSString>, notification: &UILocalNotification, response_info: &NSDictionary, completion_handler: &DynBlock<dyn Fn()>, )
UILocalNotification and UIResponder and block2 only.§Safety
response_info generic should be of the correct type.
Sourceunsafe fn application_didReceiveRemoteNotification_fetchCompletionHandler(
&self,
application: &UIApplication,
user_info: &NSDictionary,
completion_handler: &DynBlock<dyn Fn(UIBackgroundFetchResult)>,
)
Available on crate features UIResponder and block2 only.
unsafe fn application_didReceiveRemoteNotification_fetchCompletionHandler( &self, application: &UIApplication, user_info: &NSDictionary, completion_handler: &DynBlock<dyn Fn(UIBackgroundFetchResult)>, )
UIResponder and block2 only.This delegate method offers an opportunity for applications with the “remote-notification” background mode to fetch appropriate new data in response to an incoming remote notification. You should call the fetchCompletionHandler as soon as you’re finished performing that operation, so the system can accurately estimate its power and data cost.
This method will be invoked even if the application was launched or resumed because of the remote notification. The respective delegate methods will be invoked first. Note that this behavior is in contrast to application:didReceiveRemoteNotification:, which is not called in those cases, and which will not be invoked if this method is implemented. !
§Safety
user_info generic should be of the correct type.
Sourcefn application_performFetchWithCompletionHandler(
&self,
application: &UIApplication,
completion_handler: &DynBlock<dyn Fn(UIBackgroundFetchResult)>,
)
👎Deprecated: Use a BGAppRefreshTask in the BackgroundTasks framework insteadAvailable on crate features UIResponder and block2 only.
fn application_performFetchWithCompletionHandler( &self, application: &UIApplication, completion_handler: &DynBlock<dyn Fn(UIBackgroundFetchResult)>, )
UIResponder and block2 only.Applications with the “fetch” background mode may be given opportunities to fetch updated content in the background or when it is convenient for the system. This method will be called in these situations. You should call the fetchCompletionHandler as soon as you’re finished performing that operation, so the system can accurately estimate its power and data cost.
Sourcefn application_performActionForShortcutItem_completionHandler(
&self,
application: &UIApplication,
shortcut_item: &UIApplicationShortcutItem,
completion_handler: &DynBlock<dyn Fn(Bool)>,
)
👎Deprecated: Use UIScene lifecycle and windowScene(_:performActionFor:completionHandler:) from UIWindowSceneDelegate instead.Available on crate features UIApplicationShortcutItem and UIResponder and block2 only.
fn application_performActionForShortcutItem_completionHandler( &self, application: &UIApplication, shortcut_item: &UIApplicationShortcutItem, completion_handler: &DynBlock<dyn Fn(Bool)>, )
UIApplicationShortcutItem and UIResponder and block2 only.Called when the user activates your application by selecting a shortcut on the home screen, except when application(_:willFinishLaunchingWithOptions:)
or application(_:didFinishLaunchingWithOptions:) returns false.
fn application_handleEventsForBackgroundURLSession_completionHandler( &self, application: &UIApplication, identifier: &NSString, completion_handler: &DynBlock<dyn Fn()>, )
UIResponder and block2 only.Sourceunsafe fn application_handleWatchKitExtensionRequest_reply(
&self,
application: &UIApplication,
user_info: Option<&NSDictionary>,
reply: &DynBlock<dyn Fn(*mut NSDictionary)>,
)
Available on crate features UIResponder and block2 only.
unsafe fn application_handleWatchKitExtensionRequest_reply( &self, application: &UIApplication, user_info: Option<&NSDictionary>, reply: &DynBlock<dyn Fn(*mut NSDictionary)>, )
UIResponder and block2 only.§Safety
user_info generic should be of the correct type.
fn applicationShouldRequestHealthAuthorization( &self, application: &UIApplication, )
UIResponder only.UIResponder only.fn applicationProtectedDataDidBecomeAvailable( &self, application: &UIApplication, )
UIResponder only.fn window(&self) -> Option<Retained<UIWindow>>
UIResponder and UIView and UIWindow only.Sourcefn setWindow(&self, window: Option<&UIWindow>)
Available on crate features UIResponder and UIView and UIWindow only.
fn setWindow(&self, window: Option<&UIWindow>)
UIResponder and UIView and UIWindow only.Setter for window.
fn application_supportedInterfaceOrientationsForWindow( &self, application: &UIApplication, window: Option<&UIWindow>, ) -> UIInterfaceOrientationMask
UIOrientation and UIResponder and UIView and UIWindow only.fn application_shouldAllowExtensionPointIdentifier( &self, application: &UIApplication, extension_point_identifier: &UIApplicationExtensionPointIdentifier, ) -> bool
UIResponder only.Sourceunsafe fn application_viewControllerWithRestorationIdentifierPath_coder(
&self,
application: &UIApplication,
identifier_components: &NSArray<NSString>,
coder: &NSCoder,
) -> Option<Retained<UIViewController>>
Available on crate features UIResponder and UIViewController only.
unsafe fn application_viewControllerWithRestorationIdentifierPath_coder( &self, application: &UIApplication, identifier_components: &NSArray<NSString>, coder: &NSCoder, ) -> Option<Retained<UIViewController>>
UIResponder and UIViewController only.§Safety
coder possibly has further requirements.
Sourceunsafe fn application_shouldSaveSecureApplicationState(
&self,
application: &UIApplication,
coder: &NSCoder,
) -> bool
Available on crate feature UIResponder only.
unsafe fn application_shouldSaveSecureApplicationState( &self, application: &UIApplication, coder: &NSCoder, ) -> bool
UIResponder only.§Safety
coder possibly has further requirements.
Sourceunsafe fn application_shouldRestoreSecureApplicationState(
&self,
application: &UIApplication,
coder: &NSCoder,
) -> bool
Available on crate feature UIResponder only.
unsafe fn application_shouldRestoreSecureApplicationState( &self, application: &UIApplication, coder: &NSCoder, ) -> bool
UIResponder only.§Safety
coder possibly has further requirements.
Sourceunsafe fn application_willEncodeRestorableStateWithCoder(
&self,
application: &UIApplication,
coder: &NSCoder,
)
Available on crate feature UIResponder only.
unsafe fn application_willEncodeRestorableStateWithCoder( &self, application: &UIApplication, coder: &NSCoder, )
UIResponder only.§Safety
coder possibly has further requirements.
Sourceunsafe fn application_didDecodeRestorableStateWithCoder(
&self,
application: &UIApplication,
coder: &NSCoder,
)
Available on crate feature UIResponder only.
unsafe fn application_didDecodeRestorableStateWithCoder( &self, application: &UIApplication, coder: &NSCoder, )
UIResponder only.§Safety
coder possibly has further requirements.
Sourceunsafe fn application_shouldSaveApplicationState(
&self,
application: &UIApplication,
coder: &NSCoder,
) -> bool
👎Deprecated: Use application:shouldSaveSecureApplicationState: insteadAvailable on crate feature UIResponder only.
unsafe fn application_shouldSaveApplicationState( &self, application: &UIApplication, coder: &NSCoder, ) -> bool
UIResponder only.§Safety
coder possibly has further requirements.
Sourceunsafe fn application_shouldRestoreApplicationState(
&self,
application: &UIApplication,
coder: &NSCoder,
) -> bool
👎Deprecated: Use application:shouldRestoreSecureApplicationState: insteadAvailable on crate feature UIResponder only.
unsafe fn application_shouldRestoreApplicationState( &self, application: &UIApplication, coder: &NSCoder, ) -> bool
UIResponder only.§Safety
coder possibly has further requirements.
Sourcefn application_willContinueUserActivityWithType(
&self,
application: &UIApplication,
user_activity_type: &NSString,
) -> bool
👎Deprecated: Use UIScene lifecycle and scene(_:willContinueUserActivityWithType:) from UISceneDelegate instead.Available on crate feature UIResponder only.
fn application_willContinueUserActivityWithType( &self, application: &UIApplication, user_activity_type: &NSString, ) -> bool
UIResponder only.Called on the main thread as soon as the user indicates they want to continue an activity in your application. The NSUserActivity object may not be available
instantly, so use this as an opportunity to show the user that an activity will be continued shortly.
For each application(_:willContinueUserActivityWithType:) invocation, you are guaranteed to get exactly one invocation of application(_:continue:restorationHandler:)
on success, or application(_:didFailToContinueUserActivityWithType:error:) if an error was encountered.
Sourcefn application_continueUserActivity_restorationHandler(
&self,
application: &UIApplication,
user_activity: &NSUserActivity,
restoration_handler: &DynBlock<dyn Fn(*mut NSArray<ProtocolObject<dyn UIUserActivityRestoring>>)>,
) -> bool
👎Deprecated: Use UIScene lifecycle and scene(_:continue:) from UISceneDelegate instead.Available on crate features UIResponder and UIUserActivity and block2 only.
fn application_continueUserActivity_restorationHandler( &self, application: &UIApplication, user_activity: &NSUserActivity, restoration_handler: &DynBlock<dyn Fn(*mut NSArray<ProtocolObject<dyn UIUserActivityRestoring>>)>, ) -> bool
UIResponder and UIUserActivity and block2 only.Called on the main thread after the NSUserActivity object is available. Use the data you stored in the NSUserActivity object to re-create what the user
was doing. You can create/fetch any restorable objects associated with the user activity, and pass them to the restorationHandler. They will then have the
UIResponder restoreUserActivityState: method invoked with the user activity. Invoking the restorationHandler is optional. It may be copied and
invoked later, and it will bounce to the main thread to complete its work and call restoreUserActivityState on all objects.
Sourcefn application_didFailToContinueUserActivityWithType_error(
&self,
application: &UIApplication,
user_activity_type: &NSString,
error: &NSError,
)
👎Deprecated: Use UIScene lifecycle and scene(_:didFailToContinueUserActivityWithType:error:) from UISceneDelegate instead.Available on crate feature UIResponder only.
fn application_didFailToContinueUserActivityWithType_error( &self, application: &UIApplication, user_activity_type: &NSString, error: &NSError, )
UIResponder only.If the user activity cannot be fetched after application(_:willContinueUserActivityWithType:) is called, this will be called on the main thread when implemented.
Sourcefn application_didUpdateUserActivity(
&self,
application: &UIApplication,
user_activity: &NSUserActivity,
)
👎Deprecated: Use UIScene lifecycle and scene(_:didUpdate) from UISceneDelegate instead.Available on crate feature UIResponder only.
fn application_didUpdateUserActivity( &self, application: &UIApplication, user_activity: &NSUserActivity, )
UIResponder only.This is called on the main thread when a user activity managed by UIKit has been updated. You can use this as a last chance to add additional data to the userActivity.
👎Deprecated: Use UIScene lifecycle and windowScene(_:userDidAcceptCloudKitShareWith:) from UIWindowSceneDelegate instead.Available on crate features UIResponder and objc2-cloud-kit only.
UIResponder and objc2-cloud-kit only.This will be called on the main thread after the user indicates they want to accept a CloudKit sharing invitation in your application.
You should use the CKShareMetadata object’s shareURL and containerIdentifier to schedule a CKAcceptSharesOperation, then start using
the resulting CKShare and its associated record(s), which will appear in the CKContainer’s shared database in a zone matching that of the record’s owner.
fn application_configurationForConnectingSceneSession_options( &self, application: &UIApplication, connecting_scene_session: &UISceneSession, options: &UISceneConnectionOptions, ) -> Retained<UISceneConfiguration>
UIResponder and UISceneConfiguration and UISceneOptions and UISceneSession only.fn application_didDiscardSceneSessions( &self, application: &UIApplication, scene_sessions: &NSSet<UISceneSession>, )
UIResponder and UISceneSession only.fn applicationShouldAutomaticallyLocalizeKeyCommands( &self, application: &UIApplication, ) -> bool
UIResponder only.