objc2_ui_kit/generated/
UIPopoverBackgroundView.rs1use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6#[cfg(feature = "objc2-core-foundation")]
7use objc2_core_foundation::*;
8use objc2_foundation::*;
9#[cfg(feature = "objc2-quartz-core")]
10#[cfg(not(target_os = "watchos"))]
11use objc2_quartz_core::*;
12
13use crate::*;
14
15extern_protocol!(
16 pub unsafe trait UIPopoverBackgroundViewMethods {
18 #[cfg(feature = "objc2-core-foundation")]
19 #[unsafe(method(arrowBase))]
20 #[unsafe(method_family = none)]
21 fn arrowBase() -> CGFloat;
22
23 #[cfg(all(feature = "UIGeometry", feature = "objc2-core-foundation"))]
24 #[unsafe(method(contentViewInsets))]
25 #[unsafe(method_family = none)]
26 fn contentViewInsets() -> UIEdgeInsets;
27
28 #[cfg(feature = "objc2-core-foundation")]
29 #[unsafe(method(arrowHeight))]
30 #[unsafe(method_family = none)]
31 fn arrowHeight() -> CGFloat;
32 }
33);
34
35extern_class!(
36 #[unsafe(super(UIView, UIResponder, NSObject))]
38 #[derive(Debug, PartialEq, Eq, Hash)]
39 #[cfg(all(feature = "UIResponder", feature = "UIView"))]
40 pub struct UIPopoverBackgroundView;
41);
42
43#[cfg(all(
44 feature = "UIResponder",
45 feature = "UIView",
46 feature = "objc2-quartz-core"
47))]
48#[cfg(not(target_os = "watchos"))]
49extern_conformance!(
50 unsafe impl CALayerDelegate for UIPopoverBackgroundView {}
51);
52
53#[cfg(all(feature = "UIResponder", feature = "UIView"))]
54extern_conformance!(
55 unsafe impl NSCoding for UIPopoverBackgroundView {}
56);
57
58#[cfg(all(feature = "UIResponder", feature = "UIView"))]
59extern_conformance!(
60 unsafe impl NSObjectProtocol for UIPopoverBackgroundView {}
61);
62
63#[cfg(all(feature = "UIAppearance", feature = "UIResponder", feature = "UIView"))]
64extern_conformance!(
65 unsafe impl UIAppearance for UIPopoverBackgroundView {}
66);
67
68#[cfg(all(feature = "UIAppearance", feature = "UIResponder", feature = "UIView"))]
69extern_conformance!(
70 unsafe impl UIAppearanceContainer for UIPopoverBackgroundView {}
71);
72
73#[cfg(all(feature = "UIResponder", feature = "UIView"))]
74extern_conformance!(
75 unsafe impl UICoordinateSpace for UIPopoverBackgroundView {}
76);
77
78#[cfg(all(
79 feature = "UIDynamicBehavior",
80 feature = "UIResponder",
81 feature = "UIView"
82))]
83extern_conformance!(
84 unsafe impl UIDynamicItem for UIPopoverBackgroundView {}
85);
86
87#[cfg(all(feature = "UIFocus", feature = "UIResponder", feature = "UIView"))]
88extern_conformance!(
89 unsafe impl UIFocusEnvironment for UIPopoverBackgroundView {}
90);
91
92#[cfg(all(feature = "UIFocus", feature = "UIResponder", feature = "UIView"))]
93extern_conformance!(
94 unsafe impl UIFocusItem for UIPopoverBackgroundView {}
95);
96
97#[cfg(all(feature = "UIFocus", feature = "UIResponder", feature = "UIView"))]
98extern_conformance!(
99 unsafe impl UIFocusItemContainer for UIPopoverBackgroundView {}
100);
101
102#[cfg(all(feature = "UIResponder", feature = "UIView"))]
103extern_conformance!(
104 unsafe impl UIPopoverBackgroundViewMethods for UIPopoverBackgroundView {}
105);
106
107#[cfg(all(feature = "UIResponder", feature = "UIView"))]
108extern_conformance!(
109 unsafe impl UIResponderStandardEditActions for UIPopoverBackgroundView {}
110);
111
112#[cfg(all(
113 feature = "UIResponder",
114 feature = "UITraitCollection",
115 feature = "UIView"
116))]
117extern_conformance!(
118 unsafe impl UITraitEnvironment for UIPopoverBackgroundView {}
119);
120
121#[cfg(all(feature = "UIResponder", feature = "UIView"))]
122impl UIPopoverBackgroundView {
123 extern_methods!(
124 #[cfg(feature = "objc2-core-foundation")]
125 #[unsafe(method(arrowOffset))]
126 #[unsafe(method_family = none)]
127 pub fn arrowOffset(&self) -> CGFloat;
128
129 #[cfg(feature = "objc2-core-foundation")]
130 #[unsafe(method(setArrowOffset:))]
132 #[unsafe(method_family = none)]
133 pub fn setArrowOffset(&self, arrow_offset: CGFloat);
134
135 #[cfg(feature = "UIPopoverSupport")]
136 #[unsafe(method(arrowDirection))]
137 #[unsafe(method_family = none)]
138 pub fn arrowDirection(&self) -> UIPopoverArrowDirection;
139
140 #[cfg(feature = "UIPopoverSupport")]
141 #[unsafe(method(setArrowDirection:))]
143 #[unsafe(method_family = none)]
144 pub fn setArrowDirection(&self, arrow_direction: UIPopoverArrowDirection);
145
146 #[deprecated = "No longer supported"]
147 #[unsafe(method(wantsDefaultContentAppearance))]
148 #[unsafe(method_family = none)]
149 pub fn wantsDefaultContentAppearance(mtm: MainThreadMarker) -> bool;
150 );
151}
152
153#[cfg(all(feature = "UIResponder", feature = "UIView"))]
155impl UIPopoverBackgroundView {
156 extern_methods!(
157 #[cfg(feature = "objc2-core-foundation")]
158 #[unsafe(method(initWithFrame:))]
159 #[unsafe(method_family = init)]
160 pub fn initWithFrame(this: Allocated<Self>, frame: CGRect) -> Retained<Self>;
161
162 #[unsafe(method(initWithCoder:))]
166 #[unsafe(method_family = init)]
167 pub unsafe fn initWithCoder(
168 this: Allocated<Self>,
169 coder: &NSCoder,
170 ) -> Option<Retained<Self>>;
171
172 #[unsafe(method(init))]
173 #[unsafe(method_family = init)]
174 pub fn init(this: Allocated<Self>) -> Retained<Self>;
175 );
176}
177
178#[cfg(all(feature = "UIResponder", feature = "UIView"))]
180impl UIPopoverBackgroundView {
181 extern_methods!(
182 #[unsafe(method(new))]
183 #[unsafe(method_family = new)]
184 pub fn new(mtm: MainThreadMarker) -> Retained<Self>;
185 );
186}