objc2_ui_kit/generated/
UIVisualEffectView.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_class!(
16 #[unsafe(super(UIView, UIResponder, NSObject))]
18 #[thread_kind = MainThreadOnly]
19 #[derive(Debug, PartialEq, Eq, Hash)]
20 #[cfg(all(feature = "UIResponder", feature = "UIView"))]
21 pub struct UIVisualEffectView;
22);
23
24#[cfg(all(
25 feature = "UIResponder",
26 feature = "UIView",
27 feature = "objc2-quartz-core"
28))]
29#[cfg(not(target_os = "watchos"))]
30extern_conformance!(
31 unsafe impl CALayerDelegate for UIVisualEffectView {}
32);
33
34#[cfg(all(feature = "UIResponder", feature = "UIView"))]
35extern_conformance!(
36 unsafe impl NSCoding for UIVisualEffectView {}
37);
38
39#[cfg(all(feature = "UIResponder", feature = "UIView"))]
40extern_conformance!(
41 unsafe impl NSObjectProtocol for UIVisualEffectView {}
42);
43
44#[cfg(all(feature = "UIResponder", feature = "UIView"))]
45extern_conformance!(
46 unsafe impl NSSecureCoding for UIVisualEffectView {}
47);
48
49#[cfg(all(feature = "UIAppearance", feature = "UIResponder", feature = "UIView"))]
50extern_conformance!(
51 unsafe impl UIAppearance for UIVisualEffectView {}
52);
53
54#[cfg(all(feature = "UIAppearance", feature = "UIResponder", feature = "UIView"))]
55extern_conformance!(
56 unsafe impl UIAppearanceContainer for UIVisualEffectView {}
57);
58
59#[cfg(all(feature = "UIResponder", feature = "UIView"))]
60extern_conformance!(
61 unsafe impl UICoordinateSpace for UIVisualEffectView {}
62);
63
64#[cfg(all(
65 feature = "UIDynamicBehavior",
66 feature = "UIResponder",
67 feature = "UIView"
68))]
69extern_conformance!(
70 unsafe impl UIDynamicItem for UIVisualEffectView {}
71);
72
73#[cfg(all(feature = "UIFocus", feature = "UIResponder", feature = "UIView"))]
74extern_conformance!(
75 unsafe impl UIFocusEnvironment for UIVisualEffectView {}
76);
77
78#[cfg(all(feature = "UIFocus", feature = "UIResponder", feature = "UIView"))]
79extern_conformance!(
80 unsafe impl UIFocusItem for UIVisualEffectView {}
81);
82
83#[cfg(all(feature = "UIFocus", feature = "UIResponder", feature = "UIView"))]
84extern_conformance!(
85 unsafe impl UIFocusItemContainer for UIVisualEffectView {}
86);
87
88#[cfg(all(feature = "UIResponder", feature = "UIView"))]
89extern_conformance!(
90 unsafe impl UIResponderStandardEditActions for UIVisualEffectView {}
91);
92
93#[cfg(all(
94 feature = "UIResponder",
95 feature = "UITraitCollection",
96 feature = "UIView"
97))]
98extern_conformance!(
99 unsafe impl UITraitEnvironment for UIVisualEffectView {}
100);
101
102#[cfg(all(feature = "UIResponder", feature = "UIView"))]
103impl UIVisualEffectView {
104 extern_methods!(
105 #[unsafe(method(contentView))]
106 #[unsafe(method_family = none)]
107 pub fn contentView(&self) -> Retained<UIView>;
108
109 #[cfg(feature = "UIVisualEffect")]
110 #[unsafe(method(effect))]
111 #[unsafe(method_family = none)]
112 pub fn effect(&self) -> Option<Retained<UIVisualEffect>>;
113
114 #[cfg(feature = "UIVisualEffect")]
115 #[unsafe(method(setEffect:))]
119 #[unsafe(method_family = none)]
120 pub fn setEffect(&self, effect: Option<&UIVisualEffect>);
121
122 #[cfg(feature = "UIVisualEffect")]
123 #[unsafe(method(initWithEffect:))]
124 #[unsafe(method_family = init)]
125 pub fn initWithEffect(
126 this: Allocated<Self>,
127 effect: Option<&UIVisualEffect>,
128 ) -> Retained<Self>;
129
130 #[unsafe(method(initWithCoder:))]
134 #[unsafe(method_family = init)]
135 pub unsafe fn initWithCoder(
136 this: Allocated<Self>,
137 coder: &NSCoder,
138 ) -> Option<Retained<Self>>;
139 );
140}
141
142#[cfg(all(feature = "UIResponder", feature = "UIView"))]
144impl UIVisualEffectView {
145 extern_methods!(
146 #[cfg(feature = "objc2-core-foundation")]
147 #[unsafe(method(initWithFrame:))]
148 #[unsafe(method_family = init)]
149 pub fn initWithFrame(this: Allocated<Self>, frame: CGRect) -> Retained<Self>;
150
151 #[unsafe(method(init))]
152 #[unsafe(method_family = init)]
153 pub fn init(this: Allocated<Self>) -> Retained<Self>;
154 );
155}
156
157#[cfg(all(feature = "UIResponder", feature = "UIView"))]
159impl UIVisualEffectView {
160 extern_methods!(
161 #[unsafe(method(new))]
162 #[unsafe(method_family = new)]
163 pub fn new(mtm: MainThreadMarker) -> Retained<Self>;
164 );
165}