objc2_ui_kit/generated/
UICollectionViewTransitionLayout.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
10use crate::*;
11
12extern_class!(
13 #[unsafe(super(UICollectionViewLayout, NSObject))]
15 #[thread_kind = MainThreadOnly]
16 #[derive(Debug, PartialEq, Eq, Hash)]
17 #[cfg(feature = "UICollectionViewLayout")]
18 pub struct UICollectionViewTransitionLayout;
19);
20
21#[cfg(feature = "UICollectionViewLayout")]
22extern_conformance!(
23 unsafe impl NSCoding for UICollectionViewTransitionLayout {}
24);
25
26#[cfg(feature = "UICollectionViewLayout")]
27extern_conformance!(
28 unsafe impl NSObjectProtocol for UICollectionViewTransitionLayout {}
29);
30
31#[cfg(feature = "UICollectionViewLayout")]
32impl UICollectionViewTransitionLayout {
33 extern_methods!(
34 #[cfg(feature = "objc2-core-foundation")]
35 #[unsafe(method(transitionProgress))]
36 #[unsafe(method_family = none)]
37 pub fn transitionProgress(&self) -> CGFloat;
38
39 #[cfg(feature = "objc2-core-foundation")]
40 #[unsafe(method(setTransitionProgress:))]
42 #[unsafe(method_family = none)]
43 pub fn setTransitionProgress(&self, transition_progress: CGFloat);
44
45 #[unsafe(method(currentLayout))]
46 #[unsafe(method_family = none)]
47 pub fn currentLayout(&self) -> Retained<UICollectionViewLayout>;
48
49 #[unsafe(method(nextLayout))]
50 #[unsafe(method_family = none)]
51 pub fn nextLayout(&self) -> Retained<UICollectionViewLayout>;
52
53 #[unsafe(method(initWithCurrentLayout:nextLayout:))]
54 #[unsafe(method_family = init)]
55 pub fn initWithCurrentLayout_nextLayout(
56 this: Allocated<Self>,
57 current_layout: &UICollectionViewLayout,
58 new_layout: &UICollectionViewLayout,
59 ) -> Retained<Self>;
60
61 #[unsafe(method(initWithCoder:))]
65 #[unsafe(method_family = init)]
66 pub unsafe fn initWithCoder(
67 this: Allocated<Self>,
68 coder: &NSCoder,
69 ) -> Option<Retained<Self>>;
70
71 #[unsafe(method(init))]
72 #[unsafe(method_family = init)]
73 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
74
75 #[cfg(feature = "objc2-core-foundation")]
76 #[unsafe(method(updateValue:forAnimatedKey:))]
77 #[unsafe(method_family = none)]
78 pub fn updateValue_forAnimatedKey(&self, value: CGFloat, key: &NSString);
79
80 #[cfg(feature = "objc2-core-foundation")]
81 #[unsafe(method(valueForAnimatedKey:))]
82 #[unsafe(method_family = none)]
83 pub fn valueForAnimatedKey(&self, key: &NSString) -> CGFloat;
84 );
85}
86
87#[cfg(feature = "UICollectionViewLayout")]
89impl UICollectionViewTransitionLayout {
90 extern_methods!(
91 #[unsafe(method(new))]
92 #[unsafe(method_family = new)]
93 pub unsafe fn new(mtm: MainThreadMarker) -> Retained<Self>;
94 );
95}