objc2_business_chat/generated/
BCChatButton.rs1use core::ptr::NonNull;
4use objc2::__framework_prelude::*;
5#[cfg(target_os = "macos")]
6use objc2_app_kit::*;
7use objc2_foundation::*;
8
9use crate::*;
10
11#[deprecated]
16#[repr(transparent)]
17#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
18pub struct BCChatButtonStyle(pub NSInteger);
19impl BCChatButtonStyle {
20 #[doc(alias = "BCChatButtonStyleLight")]
21 #[deprecated]
22 pub const Light: Self = Self(0);
23 #[doc(alias = "BCChatButtonStyleDark")]
24 #[deprecated]
25 pub const Dark: Self = Self(1);
26}
27
28unsafe impl Encode for BCChatButtonStyle {
29 const ENCODING: Encoding = NSInteger::ENCODING;
30}
31
32unsafe impl RefEncode for BCChatButtonStyle {
33 const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
34}
35
36extern_class!(
37 #[unsafe(super(NSControl, NSView, NSResponder, NSObject))]
39 #[derive(Debug, PartialEq, Eq, Hash)]
40 #[cfg(target_os = "macos")]
41 #[deprecated]
42 pub struct BCChatButton;
43);
44
45#[cfg(target_os = "macos")]
46extern_conformance!(
47 unsafe impl NSAccessibility for BCChatButton {}
48);
49
50#[cfg(target_os = "macos")]
51extern_conformance!(
52 unsafe impl NSAccessibilityElementProtocol for BCChatButton {}
53);
54
55#[cfg(target_os = "macos")]
56extern_conformance!(
57 unsafe impl NSAnimatablePropertyContainer for BCChatButton {}
58);
59
60#[cfg(target_os = "macos")]
61extern_conformance!(
62 unsafe impl NSAppearanceCustomization for BCChatButton {}
63);
64
65#[cfg(target_os = "macos")]
66extern_conformance!(
67 unsafe impl NSCoding for BCChatButton {}
68);
69
70#[cfg(target_os = "macos")]
71extern_conformance!(
72 unsafe impl NSDraggingDestination for BCChatButton {}
73);
74
75#[cfg(target_os = "macos")]
76extern_conformance!(
77 unsafe impl NSObjectProtocol for BCChatButton {}
78);
79
80#[cfg(target_os = "macos")]
81extern_conformance!(
82 unsafe impl NSUserInterfaceItemIdentification for BCChatButton {}
83);
84
85#[cfg(target_os = "macos")]
86impl BCChatButton {
87 extern_methods!(
88 #[deprecated]
96 #[unsafe(method(initWithStyle:))]
97 #[unsafe(method_family = init)]
98 pub unsafe fn initWithStyle(
99 this: Allocated<Self>,
100 style: BCChatButtonStyle,
101 ) -> Retained<Self>;
102
103 #[deprecated]
107 #[unsafe(method(initWithCoder:))]
108 #[unsafe(method_family = init)]
109 pub unsafe fn initWithCoder(
110 this: Allocated<Self>,
111 coder: &NSCoder,
112 ) -> Option<Retained<Self>>;
113 );
114}
115
116#[cfg(target_os = "macos")]
118impl BCChatButton {
119 extern_methods!(
120 #[unsafe(method(initWithFrame:))]
121 #[unsafe(method_family = init)]
122 pub unsafe fn initWithFrame(this: Allocated<Self>, frame_rect: NSRect) -> Retained<Self>;
123 );
124}
125
126#[cfg(target_os = "macos")]
128impl BCChatButton {
129 extern_methods!(
130 #[unsafe(method(init))]
131 #[unsafe(method_family = init)]
132 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
133 );
134}
135
136#[cfg(target_os = "macos")]
138impl BCChatButton {
139 extern_methods!(
140 #[unsafe(method(new))]
141 #[unsafe(method_family = new)]
142 pub unsafe fn new(mtm: MainThreadMarker) -> Retained<Self>;
143 );
144}