pub enum Msg {
Show 16 variants
Key(KeyEvent),
Resize(u16, u16),
Tick,
TreeBatch {
req: TreeReq,
elements: Vec<Element>,
errors: usize,
done: bool,
},
TreeFailed {
req: TreeReq,
error: String,
},
ContentsLoaded {
page: usize,
refs: Vec<ObjRef>,
},
ContentsFailed {
page: usize,
error: String,
},
InspectorLoaded {
generation: u64,
payload: InspectorPayload,
},
InspectorFailed {
generation: u64,
error: String,
},
HexLoaded {
generation: u64,
window_start: u64,
total_len: u64,
bytes: Vec<u8>,
},
HexFailed {
generation: u64,
error: String,
},
SearchResult {
generation: u64,
hit: SearchHit,
},
SearchDone {
generation: u64,
},
PreviewReady {
generation: u64,
result: Result<PreviewFrame, String>,
},
MarkdownReady {
generation: u64,
result: Result<String, String>,
},
Yanked {
result: Result<String, String>,
},
}Expand description
Everything that can happen to the app: terminal input, timer ticks and
background-task completions. App::update consumes exactly these.
Variants§
Key(KeyEvent)
A key press from the crossterm event stream.
Resize(u16, u16)
Terminal resized to (width, height) cells.
Tick
100 ms heartbeat: spinner, toast expiry, resize debounce.
TreeBatch
A batch of streamed elements for a lazily populated tree section.
Fields
TreeFailed
A tree population task failed outright.
ContentsLoaded
A page’s /Contents refs arrived.
ContentsFailed
Fetching a page’s /Contents failed.
InspectorLoaded
The selected element’s data arrived for the inspector.
InspectorFailed
Loading the inspector payload failed.
HexLoaded
A window of bytes for the hex pane.
HexFailed
Reading hex bytes failed.
SearchResult
One incremental search hit.
SearchDone
The search task visited every object.
PreviewReady
A page preview render finished (or failed).
MarkdownReady
A page’s Markdown extraction finished (or failed).
Yanked
A yank finished: the toast text, or what went wrong.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Msg
impl RefUnwindSafe for Msg
impl Send for Msg
impl Sync for Msg
impl Unpin for Msg
impl UnsafeUnpin for Msg
impl UnwindSafe for Msg
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