#[repr(C)]pub enum EventSource {
User = 0,
Programmatic = 1,
Synthetic = 2,
Lifecycle = 3,
}Expand description
Tracks the origin of an event for proper handling.
This allows the system to distinguish between user input, programmatic changes, and synthetic events generated by UI components.
Variants§
User = 0
Direct user input (mouse, keyboard, touch, gamepad)
Programmatic = 1
API call (programmatic scroll, focus change, etc.)
Synthetic = 2
Generated from UI interaction (scrollbar drag, synthetic events)
Lifecycle = 3
Generated from lifecycle hooks (mount, unmount, resize)
Trait Implementations§
Source§impl Clone for EventSource
impl Clone for EventSource
Source§fn clone(&self) -> EventSource
fn clone(&self) -> EventSource
Returns a duplicate 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 EventSource
impl Debug for EventSource
Source§impl Hash for EventSource
impl Hash for EventSource
Source§impl Ord for EventSource
impl Ord for EventSource
Source§fn cmp(&self, other: &EventSource) -> Ordering
fn cmp(&self, other: &EventSource) -> 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 for EventSource
impl PartialEq for EventSource
Source§impl PartialOrd for EventSource
impl PartialOrd for EventSource
impl Copy for EventSource
impl Eq for EventSource
impl StructuralPartialEq for EventSource
Auto Trait Implementations§
impl Freeze for EventSource
impl RefUnwindSafe for EventSource
impl Send for EventSource
impl Sync for EventSource
impl Unpin for EventSource
impl UnwindSafe for EventSource
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more