objc2_app_kit/generated/
NSWindowTabGroup.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/nswindowtabgroup?language=objc)
12    #[unsafe(super(NSObject))]
13    #[thread_kind = MainThreadOnly]
14    #[derive(Debug, PartialEq, Eq, Hash)]
15    pub struct NSWindowTabGroup;
16);
17
18extern_conformance!(
19    unsafe impl NSObjectProtocol for NSWindowTabGroup {}
20);
21
22impl NSWindowTabGroup {
23    extern_methods!(
24        #[cfg(feature = "NSWindow")]
25        #[unsafe(method(identifier))]
26        #[unsafe(method_family = none)]
27        pub fn identifier(&self) -> Retained<NSWindowTabbingIdentifier>;
28
29        #[cfg(all(feature = "NSResponder", feature = "NSWindow"))]
30        #[unsafe(method(windows))]
31        #[unsafe(method_family = none)]
32        pub fn windows(&self) -> Retained<NSArray<NSWindow>>;
33
34        #[unsafe(method(isOverviewVisible))]
35        #[unsafe(method_family = none)]
36        pub fn isOverviewVisible(&self) -> bool;
37
38        /// Setter for [`isOverviewVisible`][Self::isOverviewVisible].
39        #[unsafe(method(setOverviewVisible:))]
40        #[unsafe(method_family = none)]
41        pub fn setOverviewVisible(&self, overview_visible: bool);
42
43        #[unsafe(method(isTabBarVisible))]
44        #[unsafe(method_family = none)]
45        pub fn isTabBarVisible(&self) -> bool;
46
47        #[cfg(all(feature = "NSResponder", feature = "NSWindow"))]
48        #[unsafe(method(selectedWindow))]
49        #[unsafe(method_family = none)]
50        pub fn selectedWindow(&self) -> Option<Retained<NSWindow>>;
51
52        #[cfg(all(feature = "NSResponder", feature = "NSWindow"))]
53        /// Setter for [`selectedWindow`][Self::selectedWindow].
54        ///
55        /// This is a [weak property][objc2::topics::weak_property].
56        #[unsafe(method(setSelectedWindow:))]
57        #[unsafe(method_family = none)]
58        pub fn setSelectedWindow(&self, selected_window: Option<&NSWindow>);
59
60        #[cfg(all(feature = "NSResponder", feature = "NSWindow"))]
61        #[unsafe(method(addWindow:))]
62        #[unsafe(method_family = none)]
63        pub fn addWindow(&self, window: &NSWindow);
64
65        #[cfg(all(feature = "NSResponder", feature = "NSWindow"))]
66        #[unsafe(method(insertWindow:atIndex:))]
67        #[unsafe(method_family = none)]
68        pub fn insertWindow_atIndex(&self, window: &NSWindow, index: NSInteger);
69
70        #[cfg(all(feature = "NSResponder", feature = "NSWindow"))]
71        #[unsafe(method(removeWindow:))]
72        #[unsafe(method_family = none)]
73        pub fn removeWindow(&self, window: &NSWindow);
74    );
75}
76
77/// Methods declared on superclass `NSObject`.
78impl NSWindowTabGroup {
79    extern_methods!(
80        #[unsafe(method(init))]
81        #[unsafe(method_family = init)]
82        pub fn init(this: Allocated<Self>) -> Retained<Self>;
83
84        #[unsafe(method(new))]
85        #[unsafe(method_family = new)]
86        pub fn new(mtm: MainThreadMarker) -> Retained<Self>;
87    );
88}