Struct rebind::InputRebind [] [src]

pub struct InputRebind<A: Action, S: BuildHasher = RandomState> { /* fields omitted */ }

An interface for rebinding keys to actions. This is freely convertable to and from an InputTranslator.

Methods

impl<A: Action, S: BuildHasher + Default> InputRebind<A, S>
[src]

Creates a new InputRebind with no stored Action/ButtonTuple pairs.

Insert an Action into this InputRebind. If the Action is already in the InputRebind, then its ButtonTuple will be reset to (None, None, None), and the old ButtonTuple will be returned.

Insert an Action into this InputRebind, and assign it to the ButtonTuple. If the Action is already in the InputRebind, the old ButtonTuple will be returned.

Return a reference to the current ButtonTuple stored for an action. If the action is not stored in this InputRebind, then None will be returned.

Returns a mutable reference to the current ButtonTuple stored for an action. If the action is not stored in this InputRebind, then None will be returned.

Returns whether mouse scroll along the x axis is inverted.

Set whether mouse scroll along the x axis is inverted.

Returns whether mouse scroll along the y axis is inverted.

Set whether mouse scroll along the y axis is inverted.

Returns whether mouse motion along the x axis is inverted.

Set whether mouse motion along the x axis is inverted.

Returns whether mouse scroll along the y axis is inverted.

Set whether mouse scroll along the y axis is inverted.

Returns the viewport size used for calculating mouse positions.

Set the viewport size used for calculating mouse positions.

Convert the InputRebind into an InputTranslator. Consumes the InputRebind.

Trait Implementations

impl<A: Clone + Action, S: Clone + BuildHasher> Clone for InputRebind<A, S>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl<A: Debug + Action, S: Debug + BuildHasher> Debug for InputRebind<A, S>
[src]

Formats the value using the given formatter.

impl<A: PartialEq + Action, S: PartialEq + BuildHasher> PartialEq for InputRebind<A, S>
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl<A: Action, S: BuildHasher + Default> Into<InputTranslator<A, S>> for InputRebind<A, S>
[src]

Performs the conversion.