ToastLayer view
The stack of notifications for one window.
A view survives a frame. Hold it in an Entity with cx.new(..) and reach it with .update(..).
use gpui_kit::overlay::ToastLayer;
Construct
new(cx: &mut Context<Self>) -> SelfOptions
Chain onto the value.
corner(corner: ToastCorner) -> Self
capacity(capacity: usize) -> SelfCommands
Need a Context, so they need a view.
push(toast: Toast, cx: &mut Context<Self>)
dismiss(ident: &str, cx: &mut Context<Self>) -> bool
clear(cx: &mut Context<Self>)Queries
Only answer; they change nothing.
len() -> usize
is_empty() -> bool
phase(ident: &str) -> Option<Phase>Rendered by
Each of these compiles and is captured by the gate, so the code behind them is verified rather than written.