objc2_ui_kit/generated/
UIViewConfigurationState.rs1use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6use objc2_foundation::*;
7
8use crate::*;
9
10extern_class!(
11 #[unsafe(super(NSObject))]
13 #[thread_kind = MainThreadOnly]
14 #[derive(Debug, PartialEq, Eq, Hash)]
15 pub struct UIViewConfigurationState;
16);
17
18extern_conformance!(
19 unsafe impl NSCoding for UIViewConfigurationState {}
20);
21
22extern_conformance!(
23 unsafe impl NSCopying for UIViewConfigurationState {}
24);
25
26unsafe impl CopyingHelper for UIViewConfigurationState {
27 type Result = Self;
28}
29
30extern_conformance!(
31 unsafe impl NSObjectProtocol for UIViewConfigurationState {}
32);
33
34extern_conformance!(
35 unsafe impl NSSecureCoding for UIViewConfigurationState {}
36);
37
38#[cfg(feature = "UIConfigurationState")]
39extern_conformance!(
40 unsafe impl UIConfigurationState for UIViewConfigurationState {}
41);
42
43impl UIViewConfigurationState {
44 extern_methods!(
45 #[cfg(feature = "UITraitCollection")]
46 #[unsafe(method(initWithTraitCollection:))]
48 #[unsafe(method_family = init)]
49 pub fn initWithTraitCollection(
50 this: Allocated<Self>,
51 trait_collection: &UITraitCollection,
52 ) -> Retained<Self>;
53
54 #[unsafe(method(initWithCoder:))]
58 #[unsafe(method_family = init)]
59 pub unsafe fn initWithCoder(
60 this: Allocated<Self>,
61 coder: &NSCoder,
62 ) -> Option<Retained<Self>>;
63
64 #[unsafe(method(init))]
65 #[unsafe(method_family = init)]
66 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
67
68 #[unsafe(method(new))]
69 #[unsafe(method_family = new)]
70 pub unsafe fn new(mtm: MainThreadMarker) -> Retained<Self>;
71
72 #[cfg(feature = "UITraitCollection")]
73 #[unsafe(method(traitCollection))]
74 #[unsafe(method_family = none)]
75 pub fn traitCollection(&self) -> Retained<UITraitCollection>;
76
77 #[cfg(feature = "UITraitCollection")]
78 #[unsafe(method(setTraitCollection:))]
80 #[unsafe(method_family = none)]
81 pub fn setTraitCollection(&self, trait_collection: &UITraitCollection);
82
83 #[unsafe(method(isDisabled))]
84 #[unsafe(method_family = none)]
85 pub fn isDisabled(&self) -> bool;
86
87 #[unsafe(method(setDisabled:))]
89 #[unsafe(method_family = none)]
90 pub fn setDisabled(&self, disabled: bool);
91
92 #[unsafe(method(isHighlighted))]
93 #[unsafe(method_family = none)]
94 pub fn isHighlighted(&self) -> bool;
95
96 #[unsafe(method(setHighlighted:))]
98 #[unsafe(method_family = none)]
99 pub fn setHighlighted(&self, highlighted: bool);
100
101 #[unsafe(method(isSelected))]
102 #[unsafe(method_family = none)]
103 pub fn isSelected(&self) -> bool;
104
105 #[unsafe(method(setSelected:))]
107 #[unsafe(method_family = none)]
108 pub fn setSelected(&self, selected: bool);
109
110 #[unsafe(method(isFocused))]
111 #[unsafe(method_family = none)]
112 pub fn isFocused(&self) -> bool;
113
114 #[unsafe(method(setFocused:))]
116 #[unsafe(method_family = none)]
117 pub fn setFocused(&self, focused: bool);
118
119 #[unsafe(method(isPinned))]
120 #[unsafe(method_family = none)]
121 pub fn isPinned(&self) -> bool;
122
123 #[unsafe(method(setPinned:))]
125 #[unsafe(method_family = none)]
126 pub fn setPinned(&self, pinned: bool);
127 );
128}