pub struct Events {
pub window_events: Vec<WindowEventFilter>,
pub hover_events: Vec<HoverEventFilter>,
pub focus_events: Vec<FocusEventFilter>,
pub old_hit_node_ids: BTreeMap<DomId, BTreeMap<NodeId, HitTestItem>>,
pub old_focus_node: Option<DomNodeId>,
pub current_window_state_mouse_is_down: bool,
pub previous_window_state_mouse_is_down: bool,
pub event_was_mouse_down: bool,
pub event_was_mouse_leave: bool,
pub event_was_mouse_release: bool,
}Fields§
§window_events: Vec<WindowEventFilter>§hover_events: Vec<HoverEventFilter>§focus_events: Vec<FocusEventFilter>§old_hit_node_ids: BTreeMap<DomId, BTreeMap<NodeId, HitTestItem>>§old_focus_node: Option<DomNodeId>§current_window_state_mouse_is_down: bool§previous_window_state_mouse_is_down: bool§event_was_mouse_down: bool§event_was_mouse_leave: bool§event_was_mouse_release: boolImplementations§
Source§impl Events
impl Events
Sourcepub fn new(
current_window_state: &FullWindowState,
previous_window_state: &Option<FullWindowState>,
) -> Self
pub fn new( current_window_state: &FullWindowState, previous_window_state: &Option<FullWindowState>, ) -> Self
Warning: if the previous_window_state is none, this will return an empty Vec!
pub fn is_empty(&self) -> bool
Sourcepub fn contains_resize_event(&self) -> bool
pub fn contains_resize_event(&self) -> bool
Checks whether the event was a resize event
pub fn event_was_mouse_scroll(&self) -> bool
pub fn needs_hit_test(&self) -> bool
Trait Implementations§
impl StructuralPartialEq for Events
Auto Trait Implementations§
impl Freeze for Events
impl RefUnwindSafe for Events
impl Send for Events
impl Sync for Events
impl Unpin for Events
impl UnwindSafe for Events
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