use objc2::__framework_prelude::*;
use objc2_foundation::*;
use crate::*;
#[repr(transparent)]
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
pub struct GCPhysicalInputSourceDirection(pub NSUInteger);
impl GCPhysicalInputSourceDirection {
#[doc(alias = "GCPhysicalInputSourceDirectionNotApplicable")]
pub const NotApplicable: Self = Self(0);
#[doc(alias = "GCPhysicalInputSourceDirectionUp")]
pub const Up: Self = Self(1 << 0);
#[doc(alias = "GCPhysicalInputSourceDirectionRight")]
pub const Right: Self = Self(1 << 1);
#[doc(alias = "GCPhysicalInputSourceDirectionDown")]
pub const Down: Self = Self(1 << 2);
#[doc(alias = "GCPhysicalInputSourceDirectionLeft")]
pub const Left: Self = Self(1 << 3);
}
unsafe impl Encode for GCPhysicalInputSourceDirection {
const ENCODING: Encoding = NSUInteger::ENCODING;
}
unsafe impl RefEncode for GCPhysicalInputSourceDirection {
const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
}
extern_protocol!(
pub unsafe trait GCPhysicalInputSource: NSObjectProtocol {
#[cfg(feature = "GCInputNames")]
#[method_id(@__retain_semantics Other elementAliases)]
unsafe fn elementAliases(&self) -> Id<NSSet<NSString>>;
#[method_id(@__retain_semantics Other elementLocalizedName)]
unsafe fn elementLocalizedName(&self) -> Option<Id<NSString>>;
#[method_id(@__retain_semantics Other sfSymbolsName)]
unsafe fn sfSymbolsName(&self) -> Option<Id<NSString>>;
#[method(direction)]
unsafe fn direction(&self) -> GCPhysicalInputSourceDirection;
}
unsafe impl ProtocolType for dyn GCPhysicalInputSource {}
);