Struct tokio_hidg::ValueChange
source · pub struct ValueChange<T> { /* private fields */ }
Expand description
Pointer/cursor position change event
Implementations§
source§impl<T> ValueChange<T>
impl<T> ValueChange<T>
sourcepub fn new(data: T, relative: bool) -> ValueChange<T>
pub fn new(data: T, relative: bool) -> ValueChange<T>
Create new value change event
sourcepub fn absolute(data: T) -> ValueChange<T>
pub fn absolute(data: T) -> ValueChange<T>
Create new absolute value change event
sourcepub fn relative(data: T) -> ValueChange<T>
pub fn relative(data: T) -> ValueChange<T>
Create new relative value change event
sourcepub fn is_relative(&self) -> bool
pub fn is_relative(&self) -> bool
Is value change relative
sourcepub fn is_absolute(&self) -> bool
pub fn is_absolute(&self) -> bool
Is value change absolute
Trait Implementations§
source§impl<T> Clone for ValueChange<T>where
T: Clone,
impl<T> Clone for ValueChange<T>where
T: Clone,
source§fn clone(&self) -> ValueChange<T>
fn clone(&self) -> ValueChange<T>
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<T> Debug for ValueChange<T>where
T: Debug,
impl<T> Debug for ValueChange<T>where
T: Debug,
source§impl<T> Deref for ValueChange<T>
impl<T> Deref for ValueChange<T>
source§impl<T> DerefMut for ValueChange<T>
impl<T> DerefMut for ValueChange<T>
source§impl Extend<ValueChange<(i16, i16)>> for MouseInput
impl Extend<ValueChange<(i16, i16)>> for MouseInput
source§fn extend<T>(&mut self, iter: T)
fn extend<T>(&mut self, iter: T)
Extends a collection with the contents of an iterator. Read more
source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
🔬This is a nightly-only experimental API. (
extend_one
)Extends a collection with exactly one element.
source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
🔬This is a nightly-only experimental API. (
extend_one
)Reserves capacity in a collection for the given number of additional elements. Read more
source§impl Extend<ValueChange<i8>> for MouseInput
impl Extend<ValueChange<i8>> for MouseInput
source§fn extend<T>(&mut self, iter: T)
fn extend<T>(&mut self, iter: T)
Extends a collection with the contents of an iterator. Read more
source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
🔬This is a nightly-only experimental API. (
extend_one
)Extends a collection with exactly one element.
source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
🔬This is a nightly-only experimental API. (
extend_one
)Reserves capacity in a collection for the given number of additional elements. Read more
source§impl<T> From<(T, bool)> for ValueChange<T>
impl<T> From<(T, bool)> for ValueChange<T>
source§fn from(_: (T, bool)) -> ValueChange<T>
fn from(_: (T, bool)) -> ValueChange<T>
Converts to this type from the input type.
source§impl<T> PartialEq for ValueChange<T>where
T: PartialEq,
impl<T> PartialEq for ValueChange<T>where
T: PartialEq,
source§fn eq(&self, other: &ValueChange<T>) -> bool
fn eq(&self, other: &ValueChange<T>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl<T> Copy for ValueChange<T>where
T: Copy,
impl<T> Eq for ValueChange<T>where
T: Eq,
impl<T> StructuralPartialEq for ValueChange<T>
Auto Trait Implementations§
impl<T> Freeze for ValueChange<T>where
T: Freeze,
impl<T> RefUnwindSafe for ValueChange<T>where
T: RefUnwindSafe,
impl<T> Send for ValueChange<T>where
T: Send,
impl<T> Sync for ValueChange<T>where
T: Sync,
impl<T> Unpin for ValueChange<T>where
T: Unpin,
impl<T> UnwindSafe for ValueChange<T>where
T: UnwindSafe,
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