Skip to main content

AsKeystroke

Trait AsKeystroke 

Source
pub trait AsKeystroke {
    // Required method
    fn as_keystroke(&self) -> &Keystroke;
}
Expand description

This is a helper trait so that we can simplify the implementation of some functions

Required Methods§

Source

fn as_keystroke(&self) -> &Keystroke

Returns the GPUI representation of the keystroke.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl<T: AsKeystroke + ?Sized> AsKeystroke for &T

Implementors§