pub enum MouseButton {
Show 16 variants
Left,
Middle,
Right,
WheelUp,
WheelDown,
WheelLeft,
WheelRight,
Button4,
Button5,
Button6,
Button7,
Button8,
Button9,
Button10,
Button11,
None,
}Expand description
Mouse button or wheel direction associated with a Mouse event.
Button names describe the decoded terminal bitfield, not a physical device
guarantee. Some terminals cannot identify the released button and report
MouseButton::None instead.
Variants§
Left
Primary (left) mouse button.
Middle
Middle mouse button, often the wheel button.
Right
Secondary (right) mouse button.
WheelUp
Vertical wheel scrolled up.
WheelDown
Vertical wheel scrolled down.
WheelLeft
Horizontal wheel scrolled left.
WheelRight
Horizontal wheel scrolled right.
Button4
Additional mouse button 4 when encoded by a terminal extension.
Button5
Additional mouse button 5 when encoded by a terminal extension.
Button6
Additional mouse button 6 when encoded by a terminal extension.
Button7
Additional mouse button 7 when encoded by a terminal extension.
Button8
Additional mouse button 8 when encoded by a terminal extension.
Button9
Additional mouse button 9 when encoded by a terminal extension.
Button10
Additional mouse button 10 when encoded by a terminal extension.
Button11
Additional mouse button 11 when encoded by a terminal extension.
None
No button was reported.
This appears for legacy release records and hover-style motion where the protocol does not attach a specific held button.
Trait Implementations§
Source§impl Clone for MouseButton
impl Clone for MouseButton
Source§fn clone(&self) -> MouseButton
fn clone(&self) -> MouseButton
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for MouseButton
impl Debug for MouseButton
Source§impl Hash for MouseButton
impl Hash for MouseButton
Source§impl PartialEq for MouseButton
impl PartialEq for MouseButton
Source§fn eq(&self, other: &MouseButton) -> bool
fn eq(&self, other: &MouseButton) -> bool
self and other values to be equal, and is used by ==.