pub unsafe trait GCDirectionPadElement: GCPhysicalInputElement {
// Provided methods
unsafe fn xyAxes(&self) -> Retained<ProtocolObject<dyn GCAxis2DInput>>
where Self: Sized + Message { ... }
unsafe fn xAxis(&self) -> Retained<ProtocolObject<dyn GCAxisInput>>
where Self: Sized + Message { ... }
unsafe fn yAxis(&self) -> Retained<ProtocolObject<dyn GCAxisInput>>
where Self: Sized + Message { ... }
unsafe fn up(&self) -> Retained<AnyObject>
where Self: Sized + Message { ... }
unsafe fn down(&self) -> Retained<AnyObject>
where Self: Sized + Message { ... }
unsafe fn left(&self) -> Retained<AnyObject>
where Self: Sized + Message { ... }
unsafe fn right(&self) -> Retained<AnyObject>
where Self: Sized + Message { ... }
}Available on crate features
GCDirectionPadElement and GCPhysicalInputElement only.Expand description
An object conforming to
GCDirectionPadElementrepresents a four-way
directional control element.
A direction pad element contains a common grouping of 2 axis inputs, which can also be interpreted as 2 sets of mutually exclusive button pairs. Only one button in each pair, {up, down} and {left, right}, can be pressed at any given time.
See also Apple’s documentation
Provided Methods§
Sourceunsafe fn xyAxes(&self) -> Retained<ProtocolObject<dyn GCAxis2DInput>>
Available on crate feature GCAxis2DInput only.
unsafe fn xyAxes(&self) -> Retained<ProtocolObject<dyn GCAxis2DInput>>
GCAxis2DInput only.The x,y position of the dpad input.
Sourceunsafe fn xAxis(&self) -> Retained<ProtocolObject<dyn GCAxisInput>>
Available on crate feature GCAxisInput only.
unsafe fn xAxis(&self) -> Retained<ProtocolObject<dyn GCAxisInput>>
GCAxisInput only.The horizontal/x-component of the dpad input.
Sourceunsafe fn yAxis(&self) -> Retained<ProtocolObject<dyn GCAxisInput>>
Available on crate feature GCAxisInput only.
unsafe fn yAxis(&self) -> Retained<ProtocolObject<dyn GCAxisInput>>
GCAxisInput only.The vertical/y-component of the dpad input.
Sourceunsafe fn up(&self) -> Retained<AnyObject>
Available on crate features GCLinearInput and GCPressedStateInput only.
unsafe fn up(&self) -> Retained<AnyObject>
GCLinearInput and GCPressedStateInput only.The positive y-component of the dpad input.
Sourceunsafe fn down(&self) -> Retained<AnyObject>
Available on crate features GCLinearInput and GCPressedStateInput only.
unsafe fn down(&self) -> Retained<AnyObject>
GCLinearInput and GCPressedStateInput only.The negative y-component of the dpad input.