1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use core::ptr::NonNull;
use objc2::__framework_prelude::*;
use objc2_foundation::*;
use crate::*;
extern_class!(
/// Background the scene of the provided scene session and present the
/// activated scene in its place.
///
/// The provided scene session will be backgrounded. The activated scene will
/// be center aligned with the backgrounded scene. Closing the activated window
/// will result in the backgrounded scene reappearing.
///
/// Targeting a scene session that is currently pushed will result in an error
/// being delivered to the `errorHandler` of
/// ``-[UIApplication activateSceneSessionForRequest: errorHandler:]``.
///
/// See also [Apple's documentation](https://developer.apple.com/documentation/uikit/uiwindowscenepushplacement?language=objc)
#[unsafe(super(UIWindowScenePlacement, NSObject))]
#[derive(Debug, PartialEq, Eq, Hash)]
#[cfg(feature = "UIWindowScenePlacement")]
pub struct UIWindowScenePushPlacement;
);
#[cfg(feature = "UIWindowScenePlacement")]
extern_conformance!(
unsafe impl NSCopying for UIWindowScenePushPlacement {}
);
#[cfg(feature = "UIWindowScenePlacement")]
unsafe impl CopyingHelper for UIWindowScenePushPlacement {
type Result = Self;
}
#[cfg(feature = "UIWindowScenePlacement")]
extern_conformance!(
unsafe impl NSObjectProtocol for UIWindowScenePushPlacement {}
);
#[cfg(feature = "UIWindowScenePlacement")]
impl UIWindowScenePushPlacement {
extern_methods!(
#[cfg(feature = "UISceneSession")]
/// Creates the placement that will target the given `sceneSession`.
/// - Parameter targetSceneSession: The scene session of the window scene that will be backgrounded.
#[unsafe(method(placementTargetingSceneSession:))]
#[unsafe(method_family = none)]
pub fn placementTargetingSceneSession(
target_scene_session: &UISceneSession,
) -> Retained<Self>;
);
}
/// Methods declared on superclass `UIWindowScenePlacement`.
#[cfg(feature = "UIWindowScenePlacement")]
impl UIWindowScenePushPlacement {
extern_methods!(
#[unsafe(method(init))]
#[unsafe(method_family = init)]
pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
#[unsafe(method(new))]
#[unsafe(method_family = new)]
pub unsafe fn new() -> Retained<Self>;
);
}