#[non_exhaustive]pub enum Event {
Show 22 variants
Resize {
surface: String,
geometry: Geometry,
},
Visibility {
surface: String,
visible: bool,
},
CapabilitiesChanged,
Driving(bool),
ValueChanged {
key: String,
value: Option<Json>,
},
Live {
key: String,
payload: Json,
},
LiveDeleted {
key: String,
},
Plugin {
name: String,
payload: Json,
},
AccountChanged,
Key(Key),
Paste {
surface: String,
text: String,
},
Pointer(Pointer),
ThemeChanged,
Focus {
surface: String,
focused: bool,
},
Command(String),
CallResult {
id: CallId,
result: Result<Json>,
},
FileChanged {
watch: u32,
paths: Vec<String>,
},
WatchFailed {
watch: u32,
error: String,
},
ProcessOutput {
pid: u32,
stderr: bool,
bytes: Vec<u8>,
},
ProcessExited {
pid: u32,
status: i32,
},
PaneChanged {
kind: PaneChangeKind,
pane: Pane,
},
Interest(Interest),
}Expand description
What the host tells a plugin besides frames.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Resize
A surface changed size. The SDK has rebound it; repaint it.
Visibility
A surface became visible or hidden.
CapabilitiesChanged
Graphics support, cell pixel size or frame rate changed
(capabilities).
Driving(bool)
crate::view::is_driving changed.
ValueChanged
A watched value changed (crate::values::Values::watch).
Live
A live message (crate::live::Live::subscribe).
LiveDeleted
A live key was withdrawn (crate::live::Live::delete).
Plugin
A plugin event (crate::events::Events::on).
AccountChanged
The account changed (crate::account::watch).
Key(Key)
A key on the surface with input focus.
Paste
Text pasted into the surface with input focus.
Pointer(Pointer)
The pointer over one of the plugin’s surfaces.
ThemeChanged
The viewer’s theme changed (crate::view::theme).
Focus
A surface gained or lost input focus.
Command(String)
The user ran one of the manifest’s commands, by id.
CallResult
A Calls::call_async finished:
the companion’s answer, or why there is none (a timeout is
Error::Unavailable).
FileChanged
Daemon plugins: files under a watch
changed; every path that changed since the last delivery.
WatchFailed
Daemon plugins: a watch stopped delivering (the watcher’s error).
ProcessOutput
Daemon plugins: output from a child’s piped stream.
ProcessExited
Daemon plugins: a child exited (a signal is negated), after the last of its output.
PaneChanged
Daemon plugins: a pane on the daemon’s machine changed
(panes::subscribe).
Interest(Interest)
Daemon plugins: which of the plugin’s UI surfaces the account’s
viewers show changed (Context::interest).
Start reading an outside source when any
turns true and stop when it turns false.