pub struct LayerHit {
pub layer: KeymapLayer,
pub command: Arc<BoundCommand>,
pub active: bool,
}Expand description
One layer’s hit in a KeymapResolution. Every registered layer
that has a terminal binding for the queried chord sequence
contributes one LayerHit, in priority order ascending (Builtin
first, Buffer last). The active flag is set by the caller against
the active buffer’s ActiveModes set to show which hit would
actually fire.
Fields§
§layer: KeymapLayerThe layer this binding lives in.
command: Arc<BoundCommand>The bound command at this layer.
active: boolWhether this layer is active for the buffer in question.
Always true for Builtin, User, and Buffer (always-on
layers); set by the resolve_trace caller for MajorMode
and MinorMode layers based on the buffer’s active-modes list.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for LayerHit
impl RefUnwindSafe for LayerHit
impl Send for LayerHit
impl Sync for LayerHit
impl Unpin for LayerHit
impl UnsafeUnpin for LayerHit
impl UnwindSafe for LayerHit
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