pub struct CallCallbacksResult {Show 24 fields
pub should_scroll_render: bool,
pub callbacks_update_screen: Update,
pub modified_window_state: Option<FullWindowState>,
pub words_changed: Option<BTreeMap<DomId, BTreeMap<NodeId, AzString>>>,
pub images_changed: Option<BTreeMap<DomId, BTreeMap<NodeId, (ImageRef, UpdateImageType)>>>,
pub image_masks_changed: Option<BTreeMap<DomId, BTreeMap<NodeId, ImageMask>>>,
pub image_callbacks_changed: Option<BTreeMap<DomId, FastBTreeSet<NodeId>>>,
pub css_properties_changed: Option<BTreeMap<DomId, BTreeMap<NodeId, CssPropertyVec>>>,
pub nodes_scrolled_in_callbacks: Option<BTreeMap<DomId, BTreeMap<NodeHierarchyItemId, LogicalPosition>>>,
pub update_focused_node: FocusUpdateRequest,
pub timers: Option<FastHashMap<TimerId, Timer>>,
pub threads: Option<FastHashMap<ThreadId, Thread>>,
pub timers_removed: Option<FastBTreeSet<TimerId>>,
pub threads_removed: Option<FastBTreeSet<ThreadId>>,
pub windows_created: Vec<WindowCreateOptions>,
pub menus_to_open: Vec<(Menu, Option<LogicalPosition>)>,
pub tooltips_to_show: Vec<(AzString, LogicalPosition)>,
pub hide_tooltip: bool,
pub cursor_changed: bool,
pub stop_propagation: bool,
pub prevent_default: bool,
pub hit_test_update_requested: Option<LogicalPosition>,
pub queued_window_states: Vec<FullWindowState>,
pub text_input_triggered: Vec<(DomNodeId, Vec<EventFilter>)>,
}Expand description
Result of calling callbacks, containing all state changes
Fields§
§should_scroll_render: boolWhether the UI should be rendered due to a scroll event
callbacks_update_screen: UpdateWhether the callbacks say to rebuild the UI or not
modified_window_state: Option<FullWindowState>FullWindowState that was (potentially) modified in the callbacks
words_changed: Option<BTreeMap<DomId, BTreeMap<NodeId, AzString>>>Text changes that don’t require full relayout
images_changed: Option<BTreeMap<DomId, BTreeMap<NodeId, (ImageRef, UpdateImageType)>>>Image changes (for animated images/video)
image_masks_changed: Option<BTreeMap<DomId, BTreeMap<NodeId, ImageMask>>>Clip mask changes (for vector animations)
image_callbacks_changed: Option<BTreeMap<DomId, FastBTreeSet<NodeId>>>Image callback changes (for OpenGL texture updates)
css_properties_changed: Option<BTreeMap<DomId, BTreeMap<NodeId, CssPropertyVec>>>CSS property changes from callbacks
nodes_scrolled_in_callbacks: Option<BTreeMap<DomId, BTreeMap<NodeHierarchyItemId, LogicalPosition>>>Scroll position changes from callbacks
update_focused_node: FocusUpdateRequestFocus change request from callback (if any)
timers: Option<FastHashMap<TimerId, Timer>>Timers added in callbacks
threads: Option<FastHashMap<ThreadId, Thread>>Threads added in callbacks
timers_removed: Option<FastBTreeSet<TimerId>>Timers removed in callbacks
threads_removed: Option<FastBTreeSet<ThreadId>>Threads removed in callbacks
windows_created: Vec<WindowCreateOptions>Windows created in callbacks
Menus to open (context menus or dropdowns)
tooltips_to_show: Vec<(AzString, LogicalPosition)>Tooltips to show
hide_tooltip: boolWhether to hide the currently displayed tooltip
cursor_changed: boolWhether the cursor changed
stop_propagation: boolWhether stopPropagation() was called (prevents bubbling up in DOM-style event propagation)
prevent_default: boolWhether preventDefault() was called (prevents default browser behavior)
hit_test_update_requested: Option<LogicalPosition>Hit test update requested at this position (for Debug API) When set, the shell layer should perform a hit test update before the next event dispatch
queued_window_states: Vec<FullWindowState>Queued window states to apply in sequence (for simulating clicks, etc.) The shell layer should apply these one at a time, processing events after each.
text_input_triggered: Vec<(DomNodeId, Vec<EventFilter>)>Text input events triggered by CreateTextInput
These need to be processed by the recursive event loop to invoke user callbacks
Format: Vec<(DomNodeId, Vec
Implementations§
Source§impl CallCallbacksResult
impl CallCallbacksResult
pub fn cursor_changed(&self) -> bool
pub fn focus_changed(&self) -> bool
Trait Implementations§
Source§impl CallbackResultRef for CallCallbacksResult
impl CallbackResultRef for CallCallbacksResult
fn stop_propagation(&self) -> bool
fn prevent_default(&self) -> bool
fn should_regenerate_dom(&self) -> bool
Source§impl Debug for CallCallbacksResult
impl Debug for CallCallbacksResult
Auto Trait Implementations§
impl Freeze for CallCallbacksResult
impl RefUnwindSafe for CallCallbacksResult
impl Send for CallCallbacksResult
impl Sync for CallCallbacksResult
impl Unpin for CallCallbacksResult
impl UnwindSafe for CallCallbacksResult
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
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>
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>
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