[][src]Struct druid::MouseButtons

pub struct MouseButtons(_);

A set of MouseButtons.

Implementations

impl MouseButtons[src]

pub fn new() -> MouseButtons[src]

Create a new empty set.

pub fn insert(&mut self, button: MouseButton)[src]

Add the button to the set.

pub fn remove(&mut self, button: MouseButton)[src]

Remove the button from the set.

pub fn with(self, button: MouseButton) -> MouseButtons[src]

Builder-style method for adding the button to the set.

pub fn without(self, button: MouseButton) -> MouseButtons[src]

Builder-style method for removing the button from the set.

pub fn contains(self, button: MouseButton) -> bool[src]

Returns true if the button is in the set.

pub fn is_empty(self) -> bool[src]

Returns true if the set is empty.

pub fn is_superset(self, buttons: MouseButtons) -> bool[src]

Returns true if all the buttons are in the set.

pub fn has_left(self) -> bool[src]

Returns true if MouseButton::Left is in the set.

pub fn has_right(self) -> bool[src]

Returns true if MouseButton::Right is in the set.

pub fn has_middle(self) -> bool[src]

Returns true if MouseButton::Middle is in the set.

pub fn has_x1(self) -> bool[src]

Returns true if MouseButton::X1 is in the set.

pub fn has_x2(self) -> bool[src]

Returns true if MouseButton::X2 is in the set.

pub fn extend(&mut self, buttons: MouseButtons)[src]

Adds all the buttons to the set.

pub fn union(self, other: MouseButtons) -> MouseButtons[src]

Returns a union of the values in self and other.

pub fn clear(&mut self)[src]

Clear the set.

Trait Implementations

impl Clone for MouseButtons[src]

impl Copy for MouseButtons[src]

impl Debug for MouseButtons[src]

impl Default for MouseButtons[src]

impl Eq for MouseButtons[src]

impl PartialEq<MouseButtons> for MouseButtons[src]

impl StructuralEq for MouseButtons[src]

impl StructuralPartialEq for MouseButtons[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> AnyEq for T where
    T: PartialEq<T> + Any
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> RoundFrom<T> for T

impl<T, U> RoundInto<U> for T where
    U: RoundFrom<T>, 

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.