objc2-quartz 0.3.2

Bindings to the Quartz framework
Documentation
//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use core::ffi::*;
use core::ptr::NonNull;
use objc2::__framework_prelude::*;
use objc2_app_kit::*;
use objc2_foundation::*;

use crate::*;

extern_class!(
    /// IKFilterBrowserView
    ///
    /// 2006 Apple Inc. All rights reserved.
    /// Availability: Coming to a Leopard installation near you
    ///
    /// View containing the elements of the IKFilterBrowser
    ///
    /// See discussion in IKFilterBrowserPanel
    ///
    /// See also [Apple's documentation](https://developer.apple.com/documentation/quartz/ikfilterbrowserview?language=objc)
    #[unsafe(super(NSView, NSResponder, NSObject))]
    #[derive(Debug, PartialEq, Eq, Hash)]
    pub struct IKFilterBrowserView;
);

extern_conformance!(
    unsafe impl NSAccessibility for IKFilterBrowserView {}
);

extern_conformance!(
    unsafe impl NSAccessibilityElementProtocol for IKFilterBrowserView {}
);

extern_conformance!(
    unsafe impl NSAnimatablePropertyContainer for IKFilterBrowserView {}
);

extern_conformance!(
    unsafe impl NSAppearanceCustomization for IKFilterBrowserView {}
);

extern_conformance!(
    unsafe impl NSCoding for IKFilterBrowserView {}
);

extern_conformance!(
    unsafe impl NSDraggingDestination for IKFilterBrowserView {}
);

extern_conformance!(
    unsafe impl NSObjectProtocol for IKFilterBrowserView {}
);

extern_conformance!(
    unsafe impl NSUserInterfaceItemIdentification for IKFilterBrowserView {}
);

impl IKFilterBrowserView {
    extern_methods!(
        /// Use this method to show and hide the Preview
        ///
        /// Use this method to show and hide the Preview from the program.
        ///
        /// Parameter `inState`: Boolean for visibility of the preview.
        #[unsafe(method(setPreviewState:))]
        #[unsafe(method_family = none)]
        pub unsafe fn setPreviewState(&self, in_state: bool);

        /// Returns the name of the currently selected filter.
        ///
        /// Use this method in response to a IKFilterBrowserFilterSelectedNotification or IKFilterBrowserFilterDoubleClickNotification or afer returning from a modal session.
        #[unsafe(method(filterName))]
        #[unsafe(method_family = none)]
        pub unsafe fn filterName(&self) -> Option<Retained<NSString>>;
    );
}

/// Methods declared on superclass `NSView`.
impl IKFilterBrowserView {
    extern_methods!(
        #[unsafe(method(initWithFrame:))]
        #[unsafe(method_family = init)]
        pub unsafe fn initWithFrame(this: Allocated<Self>, frame_rect: NSRect) -> Retained<Self>;

        /// # Safety
        ///
        /// `coder` possibly has further requirements.
        #[unsafe(method(initWithCoder:))]
        #[unsafe(method_family = init)]
        pub unsafe fn initWithCoder(
            this: Allocated<Self>,
            coder: &NSCoder,
        ) -> Option<Retained<Self>>;
    );
}

/// Methods declared on superclass `NSResponder`.
impl IKFilterBrowserView {
    extern_methods!(
        #[unsafe(method(init))]
        #[unsafe(method_family = init)]
        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
    );
}

/// Methods declared on superclass `NSObject`.
impl IKFilterBrowserView {
    extern_methods!(
        #[unsafe(method(new))]
        #[unsafe(method_family = new)]
        pub unsafe fn new(mtm: MainThreadMarker) -> Retained<Self>;
    );
}