objc2_tv_ui_kit/generated/
TVCollectionViewFullScreenLayout.rs1use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6#[cfg(feature = "objc2-core-foundation")]
7use objc2_core_foundation::*;
8use objc2_foundation::*;
9use objc2_ui_kit::*;
10
11use crate::*;
12
13extern_class!(
14 #[unsafe(super(UICollectionViewLayoutAttributes, NSObject))]
16 #[derive(Debug, PartialEq, Eq, Hash)]
17 pub struct TVCollectionViewFullScreenLayoutAttributes;
18);
19
20extern_conformance!(
21 unsafe impl NSCopying for TVCollectionViewFullScreenLayoutAttributes {}
22);
23
24unsafe impl CopyingHelper for TVCollectionViewFullScreenLayoutAttributes {
25 type Result = Self;
26}
27
28extern_conformance!(
29 unsafe impl NSObjectProtocol for TVCollectionViewFullScreenLayoutAttributes {}
30);
31
32extern_conformance!(
33 unsafe impl UIDynamicItem for TVCollectionViewFullScreenLayoutAttributes {}
34);
35
36impl TVCollectionViewFullScreenLayoutAttributes {
37 extern_methods!(
38 #[cfg(feature = "objc2-core-foundation")]
39 #[unsafe(method(cornerRadius))]
40 #[unsafe(method_family = none)]
41 pub unsafe fn cornerRadius(&self) -> CGFloat;
42
43 #[cfg(feature = "objc2-core-foundation")]
44 #[unsafe(method(setCornerRadius:))]
46 #[unsafe(method_family = none)]
47 pub unsafe fn setCornerRadius(&self, corner_radius: CGFloat);
48
49 #[unsafe(method(contentBleed))]
50 #[unsafe(method_family = none)]
51 pub unsafe fn contentBleed(&self) -> UIEdgeInsets;
52
53 #[unsafe(method(setContentBleed:))]
55 #[unsafe(method_family = none)]
56 pub unsafe fn setContentBleed(&self, content_bleed: UIEdgeInsets);
57
58 #[cfg(feature = "objc2-core-foundation")]
59 #[unsafe(method(normalizedPosition))]
60 #[unsafe(method_family = none)]
61 pub unsafe fn normalizedPosition(&self) -> CGFloat;
62
63 #[cfg(feature = "objc2-core-foundation")]
64 #[unsafe(method(setNormalizedPosition:))]
66 #[unsafe(method_family = none)]
67 pub unsafe fn setNormalizedPosition(&self, normalized_position: CGFloat);
68
69 #[cfg(feature = "objc2-core-foundation")]
70 #[unsafe(method(maskAmount))]
71 #[unsafe(method_family = none)]
72 pub unsafe fn maskAmount(&self) -> CGFloat;
73
74 #[cfg(feature = "objc2-core-foundation")]
75 #[unsafe(method(setMaskAmount:))]
77 #[unsafe(method_family = none)]
78 pub unsafe fn setMaskAmount(&self, mask_amount: CGFloat);
79
80 #[cfg(feature = "objc2-core-foundation")]
81 #[unsafe(method(parallaxOffset))]
82 #[unsafe(method_family = none)]
83 pub unsafe fn parallaxOffset(&self) -> CGFloat;
84
85 #[cfg(feature = "objc2-core-foundation")]
86 #[unsafe(method(setParallaxOffset:))]
88 #[unsafe(method_family = none)]
89 pub unsafe fn setParallaxOffset(&self, parallax_offset: CGFloat);
90 );
91}
92
93impl TVCollectionViewFullScreenLayoutAttributes {
95 extern_methods!(
96 #[unsafe(method(layoutAttributesForCellWithIndexPath:))]
97 #[unsafe(method_family = none)]
98 pub unsafe fn layoutAttributesForCellWithIndexPath(
99 index_path: &NSIndexPath,
100 mtm: MainThreadMarker,
101 ) -> Retained<Self>;
102
103 #[unsafe(method(layoutAttributesForSupplementaryViewOfKind:withIndexPath:))]
104 #[unsafe(method_family = none)]
105 pub unsafe fn layoutAttributesForSupplementaryViewOfKind_withIndexPath(
106 element_kind: &NSString,
107 index_path: &NSIndexPath,
108 mtm: MainThreadMarker,
109 ) -> Retained<Self>;
110
111 #[unsafe(method(layoutAttributesForDecorationViewOfKind:withIndexPath:))]
112 #[unsafe(method_family = none)]
113 pub unsafe fn layoutAttributesForDecorationViewOfKind_withIndexPath(
114 decoration_view_kind: &NSString,
115 index_path: &NSIndexPath,
116 mtm: MainThreadMarker,
117 ) -> Retained<Self>;
118 );
119}
120
121impl TVCollectionViewFullScreenLayoutAttributes {
123 extern_methods!(
124 #[unsafe(method(init))]
125 #[unsafe(method_family = init)]
126 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
127
128 #[unsafe(method(new))]
129 #[unsafe(method_family = new)]
130 pub unsafe fn new(mtm: MainThreadMarker) -> Retained<Self>;
131 );
132}
133
134extern_protocol!(
135 pub unsafe trait TVCollectionViewDelegateFullScreenLayout:
137 UICollectionViewDelegate
138 {
139 #[optional]
140 #[unsafe(method(collectionView:layout:willCenterCellAtIndexPath:))]
141 #[unsafe(method_family = none)]
142 unsafe fn collectionView_layout_willCenterCellAtIndexPath(
143 &self,
144 collection_view: &UICollectionView,
145 collection_view_layout: &UICollectionViewLayout,
146 index_path: &NSIndexPath,
147 );
148
149 #[optional]
150 #[unsafe(method(collectionView:layout:didCenterCellAtIndexPath:))]
151 #[unsafe(method_family = none)]
152 unsafe fn collectionView_layout_didCenterCellAtIndexPath(
153 &self,
154 collection_view: &UICollectionView,
155 collection_view_layout: &UICollectionViewLayout,
156 index_path: &NSIndexPath,
157 );
158 }
159);
160
161extern_class!(
162 #[unsafe(super(UICollectionViewLayout, NSObject))]
164 #[derive(Debug, PartialEq, Eq, Hash)]
165 pub struct TVCollectionViewFullScreenLayout;
166);
167
168extern_conformance!(
169 unsafe impl NSCoding for TVCollectionViewFullScreenLayout {}
170);
171
172extern_conformance!(
173 unsafe impl NSObjectProtocol for TVCollectionViewFullScreenLayout {}
174);
175
176impl TVCollectionViewFullScreenLayout {
177 extern_methods!(
178 #[cfg(feature = "objc2-core-foundation")]
179 #[unsafe(method(cornerRadius))]
180 #[unsafe(method_family = none)]
181 pub unsafe fn cornerRadius(&self) -> CGFloat;
182
183 #[cfg(feature = "objc2-core-foundation")]
184 #[unsafe(method(setCornerRadius:))]
186 #[unsafe(method_family = none)]
187 pub unsafe fn setCornerRadius(&self, corner_radius: CGFloat);
188
189 #[cfg(feature = "objc2-core-foundation")]
190 #[unsafe(method(interitemSpacing))]
191 #[unsafe(method_family = none)]
192 pub unsafe fn interitemSpacing(&self) -> CGFloat;
193
194 #[cfg(feature = "objc2-core-foundation")]
195 #[unsafe(method(setInteritemSpacing:))]
197 #[unsafe(method_family = none)]
198 pub unsafe fn setInteritemSpacing(&self, interitem_spacing: CGFloat);
199
200 #[cfg(feature = "objc2-core-foundation")]
201 #[unsafe(method(parallaxFactor))]
202 #[unsafe(method_family = none)]
203 pub unsafe fn parallaxFactor(&self) -> CGFloat;
204
205 #[cfg(feature = "objc2-core-foundation")]
206 #[unsafe(method(setParallaxFactor:))]
208 #[unsafe(method_family = none)]
209 pub unsafe fn setParallaxFactor(&self, parallax_factor: CGFloat);
210
211 #[cfg(feature = "objc2-core-foundation")]
212 #[unsafe(method(maskAmount))]
213 #[unsafe(method_family = none)]
214 pub unsafe fn maskAmount(&self) -> CGFloat;
215
216 #[cfg(feature = "objc2-core-foundation")]
217 #[unsafe(method(setMaskAmount:))]
219 #[unsafe(method_family = none)]
220 pub unsafe fn setMaskAmount(&self, mask_amount: CGFloat);
221
222 #[unsafe(method(maskInset))]
223 #[unsafe(method_family = none)]
224 pub unsafe fn maskInset(&self) -> UIEdgeInsets;
225
226 #[unsafe(method(setMaskInset:))]
228 #[unsafe(method_family = none)]
229 pub unsafe fn setMaskInset(&self, mask_inset: UIEdgeInsets);
230
231 #[unsafe(method(centerIndexPath))]
232 #[unsafe(method_family = none)]
233 pub unsafe fn centerIndexPath(&self) -> Option<Retained<NSIndexPath>>;
234
235 #[unsafe(method(isTransitioningToCenterIndexPath))]
236 #[unsafe(method_family = none)]
237 pub unsafe fn isTransitioningToCenterIndexPath(&self) -> bool;
238 );
239}
240
241impl TVCollectionViewFullScreenLayout {
243 extern_methods!(
244 #[unsafe(method(init))]
245 #[unsafe(method_family = init)]
246 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
247
248 #[unsafe(method(initWithCoder:))]
252 #[unsafe(method_family = init)]
253 pub unsafe fn initWithCoder(
254 this: Allocated<Self>,
255 coder: &NSCoder,
256 ) -> Option<Retained<Self>>;
257 );
258}
259
260impl TVCollectionViewFullScreenLayout {
262 extern_methods!(
263 #[unsafe(method(new))]
264 #[unsafe(method_family = new)]
265 pub unsafe fn new(mtm: MainThreadMarker) -> Retained<Self>;
266 );
267}