objc2_app_kit/generated/
NSSplitViewItemAccessoryViewController.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6use objc2_foundation::*;
7
8use crate::*;
9
10extern_class!(
11    /// [Apple's documentation](https://developer.apple.com/documentation/appkit/nssplitviewitemaccessoryviewcontroller?language=objc)
12    #[unsafe(super(NSViewController, NSResponder, NSObject))]
13    #[derive(Debug, PartialEq, Eq, Hash)]
14    #[cfg(all(feature = "NSResponder", feature = "NSViewController"))]
15    pub struct NSSplitViewItemAccessoryViewController;
16);
17
18#[cfg(all(
19    feature = "NSAnimation",
20    feature = "NSResponder",
21    feature = "NSViewController"
22))]
23extern_conformance!(
24    unsafe impl NSAnimatablePropertyContainer for NSSplitViewItemAccessoryViewController {}
25);
26
27#[cfg(all(feature = "NSResponder", feature = "NSViewController"))]
28extern_conformance!(
29    unsafe impl NSCoding for NSSplitViewItemAccessoryViewController {}
30);
31
32#[cfg(all(
33    feature = "NSKeyValueBinding",
34    feature = "NSResponder",
35    feature = "NSViewController"
36))]
37extern_conformance!(
38    unsafe impl NSEditor for NSSplitViewItemAccessoryViewController {}
39);
40
41#[cfg(all(feature = "NSResponder", feature = "NSViewController"))]
42extern_conformance!(
43    unsafe impl NSObjectProtocol for NSSplitViewItemAccessoryViewController {}
44);
45
46#[cfg(all(
47    feature = "NSResponder",
48    feature = "NSStoryboardSegue",
49    feature = "NSViewController"
50))]
51extern_conformance!(
52    unsafe impl NSSeguePerforming for NSSplitViewItemAccessoryViewController {}
53);
54
55#[cfg(all(
56    feature = "NSResponder",
57    feature = "NSUserInterfaceItemIdentification",
58    feature = "NSViewController"
59))]
60extern_conformance!(
61    unsafe impl NSUserInterfaceItemIdentification for NSSplitViewItemAccessoryViewController {}
62);
63
64#[cfg(all(feature = "NSResponder", feature = "NSViewController"))]
65impl NSSplitViewItemAccessoryViewController {
66    extern_methods!(
67        /// When set, this property will collapse the accessory view to 0 height (animatable) but not remove it from the window.
68        /// Set through the animator object to animate it.
69        #[unsafe(method(isHidden))]
70        #[unsafe(method_family = none)]
71        pub fn isHidden(&self) -> bool;
72
73        /// Setter for [`isHidden`][Self::isHidden].
74        #[unsafe(method(setHidden:))]
75        #[unsafe(method_family = none)]
76        pub fn setHidden(&self, hidden: bool);
77
78        /// Whether or not standard content insets should be applied to the view.
79        /// Defaults to YES.
80        #[unsafe(method(automaticallyAppliesContentInsets))]
81        #[unsafe(method_family = none)]
82        pub fn automaticallyAppliesContentInsets(&self) -> bool;
83
84        /// Setter for [`automaticallyAppliesContentInsets`][Self::automaticallyAppliesContentInsets].
85        #[unsafe(method(setAutomaticallyAppliesContentInsets:))]
86        #[unsafe(method_family = none)]
87        pub fn setAutomaticallyAppliesContentInsets(
88            &self,
89            automatically_applies_content_insets: bool,
90        );
91
92        #[unsafe(method(viewWillAppear))]
93        #[unsafe(method_family = none)]
94        pub fn viewWillAppear(&self);
95
96        #[unsafe(method(viewDidAppear))]
97        #[unsafe(method_family = none)]
98        pub fn viewDidAppear(&self);
99
100        #[unsafe(method(viewWillDisappear))]
101        #[unsafe(method_family = none)]
102        pub fn viewWillDisappear(&self);
103
104        #[unsafe(method(viewDidDisappear))]
105        #[unsafe(method_family = none)]
106        pub fn viewDidDisappear(&self);
107    );
108}
109
110/// Methods declared on superclass `NSViewController`.
111#[cfg(all(feature = "NSResponder", feature = "NSViewController"))]
112impl NSSplitViewItemAccessoryViewController {
113    extern_methods!(
114        #[cfg(feature = "NSNib")]
115        #[unsafe(method(initWithNibName:bundle:))]
116        #[unsafe(method_family = init)]
117        pub fn initWithNibName_bundle(
118            this: Allocated<Self>,
119            nib_name_or_nil: Option<&NSNibName>,
120            nib_bundle_or_nil: Option<&NSBundle>,
121        ) -> Retained<Self>;
122
123        /// # Safety
124        ///
125        /// `coder` possibly has further requirements.
126        #[unsafe(method(initWithCoder:))]
127        #[unsafe(method_family = init)]
128        pub unsafe fn initWithCoder(
129            this: Allocated<Self>,
130            coder: &NSCoder,
131        ) -> Option<Retained<Self>>;
132    );
133}
134
135/// Methods declared on superclass `NSResponder`.
136#[cfg(all(feature = "NSResponder", feature = "NSViewController"))]
137impl NSSplitViewItemAccessoryViewController {
138    extern_methods!(
139        #[unsafe(method(init))]
140        #[unsafe(method_family = init)]
141        pub fn init(this: Allocated<Self>) -> Retained<Self>;
142    );
143}
144
145/// Methods declared on superclass `NSObject`.
146#[cfg(all(feature = "NSResponder", feature = "NSViewController"))]
147impl NSSplitViewItemAccessoryViewController {
148    extern_methods!(
149        #[unsafe(method(new))]
150        #[unsafe(method_family = new)]
151        pub fn new(mtm: MainThreadMarker) -> Retained<Self>;
152    );
153}