pub unsafe trait GCDevice: NSObjectProtocol {
// Provided methods
unsafe fn vendorName(&self) -> Option<Retained<NSString>>
where Self: Sized + Message { ... }
unsafe fn productCategory(&self) -> Retained<NSString>
where Self: Sized + Message { ... }
unsafe fn physicalInputProfile(&self) -> Retained<GCPhysicalInputProfile>
where Self: Sized + Message { ... }
}
Available on crate feature
GCDevice
only.Expand description
Provided Methods§
Sourceunsafe fn vendorName(&self) -> Option<Retained<NSString>>
unsafe fn vendorName(&self) -> Option<Retained<NSString>>
A vendor supplied name. May be nil, and is not guaranteed to be unique. This should not be used as a key in a dictionary, but simply as a way to present some basic information about the device in testing or to the user.
Sourceunsafe fn productCategory(&self) -> Retained<NSString>
unsafe fn productCategory(&self) -> Retained<NSString>
The product category the device belongs to. This is useful for setting appropriate UI elements based on what type of device is connected.
See: GCProductCategories.h
Sourceunsafe fn physicalInputProfile(&self) -> Retained<GCPhysicalInputProfile>
👎Deprecated: Use the physicalInputProfile property on GCController instead. For GCKeyboard, use the keyboardInput property. For GCMouse, use the mouseInput property.Available on crate feature GCPhysicalInputProfile
only.
unsafe fn physicalInputProfile(&self) -> Retained<GCPhysicalInputProfile>
GCPhysicalInputProfile
only.Gets the physical input profile for the device.
Note: This is equivalent to the controller’s gamepad, microGamepad, or extendedGamepad instance.
See: GCController.microGamepad
See: GCController.extendedGamepad
Trait Implementations§
Source§impl ProtocolType for dyn GCDevice
impl ProtocolType for dyn GCDevice
impl<T> ImplementedBy<T> for dyn GCDevice
Implementations on Foreign Types§
impl<T> GCDevice for ProtocolObject<T>
Implementors§
impl GCDevice for GCController
Available on crate feature
GCController
only.impl GCDevice for GCKeyboard
Available on crate feature
GCKeyboard
only.impl GCDevice for GCMouse
Available on crate feature
GCMouse
only.impl GCDevice for GCRacingWheel
Available on crate feature
GCRacingWheel
only.