Enum glfw::MouseButton
source · #[repr(i32)]
pub enum MouseButton {
Button1,
Button2,
Button3,
Button4,
Button5,
Button6,
Button7,
Button8,
}
Expand description
Mouse buttons. The MouseButtonLeft
, MouseButtonRight
, and
MouseButtonMiddle
aliases are supplied for convenience.
Variants§
Button1
The left mouse button. A MouseButtonLeft
alias is provided to improve clarity.
Button2
The right mouse button. A MouseButtonRight
alias is provided to improve clarity.
Button3
The middle mouse button. A MouseButtonMiddle
alias is provided to improve clarity.
Button4
Button5
Button6
Button7
Button8
Implementations§
source§impl MouseButton
impl MouseButton
sourcepub fn from_i32(n: i32) -> Option<MouseButton>
pub fn from_i32(n: i32) -> Option<MouseButton>
Converts from i32
.
Trait Implementations§
source§impl Clone for MouseButton
impl Clone for MouseButton
source§fn clone(&self) -> MouseButton
fn clone(&self) -> MouseButton
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for MouseButton
impl Debug for MouseButton
source§impl Hash for MouseButton
impl Hash for MouseButton
source§impl Ord for MouseButton
impl Ord for MouseButton
source§fn cmp(&self, other: &MouseButton) -> Ordering
fn cmp(&self, other: &MouseButton) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq<MouseButton> for MouseButton
impl PartialEq<MouseButton> for MouseButton
source§fn eq(&self, other: &MouseButton) -> bool
fn eq(&self, other: &MouseButton) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd<MouseButton> for MouseButton
impl PartialOrd<MouseButton> for MouseButton
source§fn partial_cmp(&self, other: &MouseButton) -> Option<Ordering>
fn partial_cmp(&self, other: &MouseButton) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read more