pub struct KeySet<T: KeyboardKey + Hash> { /* private fields */ }Expand description
A set of KeyboardKeys that can be used as the keys in a map.
A key set contains the keys that are down simultaneously to represent a shortcut.
This is a thin wrapper around a set, but changes the equality comparison from an identity comparison to a contents comparison so that non-identical sets with the same keys in them will compare as equal.
See also:
ShortcutManager, which usesLogicalKeySet(aKeySetwrapper) to define its key map.
Implementations§
Trait Implementations§
impl<T: Eq + KeyboardKey + Hash> Eq for KeySet<T>
impl<T: PartialEq + KeyboardKey + Hash> StructuralPartialEq for KeySet<T>
Auto Trait Implementations§
impl<T> Forget for KeySet<T>
impl<T> Freeze for KeySet<T>
impl<T> Move for KeySet<T>
impl<T> RefUnwindSafe for KeySet<T>where
T: RefUnwindSafe,
impl<T> Send for KeySet<T>
impl<T> Sync for KeySet<T>
impl<T> Unpin for KeySet<T>
impl<T> UnsafeUnpin for KeySet<T>
impl<T> UnwindSafe for KeySet<T>
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.