pub struct System<R: Copy + Debug + PartialEq, Keys: Index<usize, Output = Key<R>>, AuxiliaryKeys: Index<usize, Output = AuxiliaryKey<R>>> { /* private fields */ }
Expand description
The key::System implementation for the chorded key system.
Implementations§
Trait Implementations§
Source§impl<R: Clone + Copy + Debug + PartialEq, Keys: Clone + Index<usize, Output = Key<R>>, AuxiliaryKeys: Clone + Index<usize, Output = AuxiliaryKey<R>>> Clone for System<R, Keys, AuxiliaryKeys>
impl<R: Clone + Copy + Debug + PartialEq, Keys: Clone + Index<usize, Output = Key<R>>, AuxiliaryKeys: Clone + Index<usize, Output = AuxiliaryKey<R>>> Clone for System<R, Keys, AuxiliaryKeys>
Source§impl<R: Debug + Copy + Debug + PartialEq, Keys: Debug + Index<usize, Output = Key<R>>, AuxiliaryKeys: Debug + Index<usize, Output = AuxiliaryKey<R>>> Debug for System<R, Keys, AuxiliaryKeys>
impl<R: Debug + Copy + Debug + PartialEq, Keys: Debug + Index<usize, Output = Key<R>>, AuxiliaryKeys: Debug + Index<usize, Output = AuxiliaryKey<R>>> Debug for System<R, Keys, AuxiliaryKeys>
Source§impl<R: PartialEq + Copy + Debug + PartialEq, Keys: PartialEq + Index<usize, Output = Key<R>>, AuxiliaryKeys: PartialEq + Index<usize, Output = AuxiliaryKey<R>>> PartialEq for System<R, Keys, AuxiliaryKeys>
impl<R: PartialEq + Copy + Debug + PartialEq, Keys: PartialEq + Index<usize, Output = Key<R>>, AuxiliaryKeys: PartialEq + Index<usize, Output = AuxiliaryKey<R>>> PartialEq for System<R, Keys, AuxiliaryKeys>
Source§impl<R: Copy + Debug + PartialEq, Keys: Debug + Index<usize, Output = Key<R>>, AuxiliaryKeys: Debug + Index<usize, Output = AuxiliaryKey<R>>> System<R> for System<R, Keys, AuxiliaryKeys>
impl<R: Copy + Debug + PartialEq, Keys: Debug + Index<usize, Output = Key<R>>, AuxiliaryKeys: Debug + Index<usize, Output = AuxiliaryKey<R>>> System<R> for System<R, Keys, AuxiliaryKeys>
Source§type Context = Context
type Context = Context
The associated Context is used to provide state that
may affect behaviour when pressing the key.
(e.g. the behaviour of layered::LayeredKey depends on which
layers are active in layered::Context).
Source§type Event = Event
type Event = Event
The associated
Event
is to be handled by the associated Context,
pending key states, and key states.Source§type PendingKeyState = PendingKeyState
type PendingKeyState = PendingKeyState
Associated pending key state.
Source§fn new_pressed_key(
&self,
keymap_index: u16,
context: &Self::Context,
key_ref: Ref,
) -> (PressedKeyResult<R, Self::PendingKeyState, Self::KeyState>, KeyEvents<Self::Event>)
fn new_pressed_key( &self, keymap_index: u16, context: &Self::Context, key_ref: Ref, ) -> (PressedKeyResult<R, Self::PendingKeyState, Self::KeyState>, KeyEvents<Self::Event>)
Produces a pressed key value, and may
yield some ScheduledEvents.
(e.g. tap_hold::Key schedules a tap_hold::Event::TapHoldTimeout
so that holding the key resolves as a hold).
Source§fn update_pending_state(
&self,
pending_state: &mut Self::PendingKeyState,
keymap_index: u16,
context: &Self::Context,
key_ref: Ref,
event: Event<Self::Event>,
) -> (Option<NewPressedKey<R>>, KeyEvents<Self::Event>)
fn update_pending_state( &self, pending_state: &mut Self::PendingKeyState, keymap_index: u16, context: &Self::Context, key_ref: Ref, event: Event<Self::Event>, ) -> (Option<NewPressedKey<R>>, KeyEvents<Self::Event>)
Update the given pending key state with the given impl.
impl<R: Copy + Copy + Debug + PartialEq, Keys: Copy + Index<usize, Output = Key<R>>, AuxiliaryKeys: Copy + Index<usize, Output = AuxiliaryKey<R>>> Copy for System<R, Keys, AuxiliaryKeys>
impl<R: Copy + Debug + PartialEq, Keys: Index<usize, Output = Key<R>>, AuxiliaryKeys: Index<usize, Output = AuxiliaryKey<R>>> StructuralPartialEq for System<R, Keys, AuxiliaryKeys>
Auto Trait Implementations§
impl<R, Keys, AuxiliaryKeys> Freeze for System<R, Keys, AuxiliaryKeys>
impl<R, Keys, AuxiliaryKeys> RefUnwindSafe for System<R, Keys, AuxiliaryKeys>where
Keys: RefUnwindSafe,
AuxiliaryKeys: RefUnwindSafe,
impl<R, Keys, AuxiliaryKeys> Send for System<R, Keys, AuxiliaryKeys>
impl<R, Keys, AuxiliaryKeys> Sync for System<R, Keys, AuxiliaryKeys>
impl<R, Keys, AuxiliaryKeys> Unpin for System<R, Keys, AuxiliaryKeys>
impl<R, Keys, AuxiliaryKeys> UnwindSafe for System<R, Keys, AuxiliaryKeys>where
Keys: UnwindSafe,
AuxiliaryKeys: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more