pub enum Event {
Show 46 variants
RichCommand {
command: RichCommand,
revision: u64,
selection: Option<TextSelection>,
},
RichRejected {
revision: u64,
},
RichEdit(Box<RichSnapshot>),
RichSelection(Box<RichSnapshot>),
Files(Box<FileEvent>),
TreeNavigate {
from: NodeId,
command: TreeCommand,
},
Clipboard {
revision: u64,
request: u64,
outcome: ClipboardOutcome,
},
GridNavigate {
from: NodeId,
command: GridCommand,
},
InputEdit(InputEdit),
CollapseComplete {
revision: u64,
},
PresenceComplete {
revision: u64,
},
ContextMenu {
from: NodeId,
point: ContextPoint,
source: ContextSource,
},
Sheet {
from: NodeId,
revision: u64,
command: SheetCommand,
},
NavigationPanel {
from: NodeId,
command: NavigationPanelCommand,
},
Spin {
from: NodeId,
command: RangeCommand,
},
Range {
from: NodeId,
command: RangeCommand,
},
ScrollKeyboard {
from: NodeId,
command: ScrollCommand,
},
ImageStatus {
revision: u64,
status: ImageStatus,
},
Menu {
from: NodeId,
command: MenuCommand,
},
PlotPointer {
from: NodeId,
pointer: PlotPointer,
},
Pointer {
from: NodeId,
related: Option<NodeId>,
phase: PointerPhase,
},
PointerWithin {
from: NodeId,
related: Option<NodeId>,
phase: PointerPhase,
},
Submit {
submitter: Option<NodeId>,
},
Reset,
Activate,
DisplayClick(u16),
Dismiss(DismissReason),
ColorSchemeChanged {
dark: bool,
},
Keyboard {
from: NodeId,
command: KeyboardCommand,
},
Palette {
from: NodeId,
},
Swipe {
from: NodeId,
phase: DragPhase,
x: f64,
y: f64,
revision: u64,
},
Drag {
from: NodeId,
phase: DragPhase,
x: f64,
y: f64,
},
ValueChanged {
value: String,
composing: bool,
revision: u64,
},
Commit {
value: String,
revision: u64,
},
CheckedChanged(bool),
Tags {
from: NodeId,
revision: u64,
command: TagsCommand,
},
Choice {
from: NodeId,
command: ChoiceCommand,
},
SelectChanged {
keys: Vec<SemanticId>,
revision: u64,
},
FocusChanged(bool),
FocusWithin {
node: NodeId,
focused: bool,
},
Navigate {
from: NodeId,
command: Navigation,
},
Typeahead {
from: NodeId,
text: String,
at_millis: u64,
},
Composition {
active: bool,
},
Scroll {
x: f64,
y: f64,
viewport: Rect,
ack: Option<ScrollAck>,
},
Resize {
size: Rect,
viewport: Rect,
},
Anchor {
row: NodeId,
within: f64,
viewport: Rect,
},
}Variants§
RichCommand
Fields
command: RichCommandselection: Option<TextSelection>Source inputs capture the exact selection at keydown; rich editors continue to use their independently accepted rich selection.
RichRejected
Current physical content exceeded the finite rich document grammar or budgets. The host restores its accepted value before publishing this.
RichEdit(Box<RichSnapshot>)
RichSelection(Box<RichSnapshot>)
Files(Box<FileEvent>)
Clipboard
InputEdit(InputEdit)
CollapseComplete
Terminal presentation observation; valid while the closing subtree is logically hidden/inert, without admitting business input there.
PresenceComplete
ContextMenu
Sheet
Spin
Range
ScrollKeyboard
ImageStatus
Terminal observation for one program-selected image request.
Menu
PlotPointer
A queued observation in an explicitly observed View’s local border box.
Pointer
PointerWithin
Logical boundary observation derived from a physical pointer origin.
Submit
Native form default behavior is cancelled before this queued request. None represents a programmatic request or implicit keyboard submission.
Reset
Activate
DisplayClick(u16)
An activation of an explicitly declared target in a display instance.
Dismiss(DismissReason)
A request only: the application may keep controlled state open.
ColorSchemeChanged
Host preference, independent of an application’s explicit appearance.
Keyboard
Physical origin remains explicit while App routes to the nearest observer.
Palette
Only the explicit palette chord; other application commands stay native.
Swipe
Start/Move/Cancel target the source. Drop targets a live accepting node.
Drag
ValueChanged
Commit
CheckedChanged(bool)
Tags
Choice
SelectChanged
FocusChanged(bool)
Direct focus origin. Hosts report this even if only an ancestor has a FocusWithin interest; App derives the logical ancestor observations.
FocusWithin
Focus transition originating at node, delivered to observing logical
ancestors (including boxless Groups). FocusChanged itself stays direct.
Origin stays explicit when routed to the nearest logical observer.
Typeahead
Composition
Scroll
Fields
Resize
Border-box size and client viewport are distinct (borders/scrollbars). Size uses local x/y=0; adapters preserve fractional layout dimensions.
Anchor
Restore an existing visible row and its pixel inset at host handover.
Implementations§
Source§impl Event
impl Event
Sourcepub fn is_user_interaction(&self) -> bool
pub fn is_user_interaction(&self) -> bool
User input is suppressed by inherited inert regions. Resource/layout observations and terminal cleanup remain available to live Owners.
Sourcepub fn is_terminal_loss(&self) -> bool
pub fn is_terminal_loss(&self) -> bool
Cleanup observations still reach live scopes after suspension. Retired identities never become valid again because an event is terminal.
Sourcepub fn validate_payload<'a>(
&self,
target: NodeId,
node: impl Into<DescriptorView<'a>>,
) -> Result<(), Error>
pub fn validate_payload<'a>( &self, target: NodeId, node: impl Into<DescriptorView<'a>>, ) -> Result<(), Error>
Check typed host input before business handlers. Embedded identities’ liveness/ancestry require a tree and are checked by Memory::validate_event. Scroll offsets may be negative; local geometry must have x/y=0.