pub struct Contact<'a, T> {
pub id: ContactId,
pub source: ContactSource,
pub phase: Phase,
pub origin: Point<T>,
pub position: Point<T>,
pub delta: Point<T>,
pub started: Duration,
pub over: bool,
pub free: bool,
/* private fields */
}Expand description
a mouse button press or touch, from down to release or cancellation
see sharing contacts for when to claim or capture
Fields§
§id: ContactId§source: ContactSource§phase: Phase§origin: Point<T>§position: Point<T>§delta: Point<T>movement since the previous input
started: Durationwhen the press started
over: booltrue if the position hits your widget or one of its children
free: boolfree for this widget to use, including contacts it captured
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl<'a, T> !UnwindSafe for Contact<'a, T>
impl<'a, T> Forget for Contact<'a, T>
impl<'a, T> Freeze for Contact<'a, T>
impl<'a, T> Move for Contact<'a, T>
impl<'a, T> RefUnwindSafe for Contact<'a, T>
impl<'a, T> Send for Contact<'a, T>
impl<'a, T> Sync for Contact<'a, T>
impl<'a, T> Unpin for Contact<'a, T>
impl<'a, T> UnsafeUnpin for Contact<'a, 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