pub enum SysMods {
None,
Shift,
Cmd,
AltCmd,
CmdShift,
AltCmdShift,
}
Expand description
A platform-agnostic representation of keyboard modifiers, for command handling.
This does one thing: it allows specifying hotkeys that use the Command key on macOS, but use the Ctrl key on other platforms.
Variants§
None
Shift
Cmd
Command on macOS, and Ctrl on Windows/Linux/OpenBSD/FreeBSD
AltCmd
Command + Alt on macOS, Ctrl + Alt on Windows/Linux/OpenBSD/FreeBSD
CmdShift
Command + Shift on macOS, Ctrl + Shift on Windows/Linux/OpenBSD/FreeBSD
AltCmdShift
Command + Alt + Shift on macOS, Ctrl + Alt + Shift on Windows/Linux/OpenBSD/FreeBSD
Trait Implementations§
source§impl PartialEq<Modifiers> for SysMods
impl PartialEq<Modifiers> for SysMods
source§impl PartialEq<SysMods> for Modifiers
impl PartialEq<SysMods> for Modifiers
impl Copy for SysMods
Auto Trait Implementations§
impl RefUnwindSafe for SysMods
impl Send for SysMods
impl Sync for SysMods
impl Unpin for SysMods
impl UnwindSafe for SysMods
Blanket Implementations§
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> RoundFrom<T> for T
impl<T> RoundFrom<T> for T
§fn round_from(x: T) -> T
fn round_from(x: T) -> T
Performs the conversion.
§impl<T, U> RoundInto<U> for Twhere
U: RoundFrom<T>,
impl<T, U> RoundInto<U> for Twhere U: RoundFrom<T>,
§fn round_into(self) -> U
fn round_into(self) -> U
Performs the conversion.