Introduce daemon API and unify shell runtimes
This commit is contained in:
parent
368b15f708
commit
341c9a3c12
54 changed files with 1352 additions and 2677 deletions
|
|
@ -78,11 +78,22 @@ impl<T: 'static> Proxy<T> {
|
|||
/// Note: This skips the backpressure mechanism with an unbounded
|
||||
/// channel. Use sparingly!
|
||||
pub fn send(&mut self, value: T)
|
||||
where
|
||||
T: std::fmt::Debug,
|
||||
{
|
||||
self.send_action(Action::Output(value));
|
||||
}
|
||||
|
||||
/// Sends an action to the event loop.
|
||||
///
|
||||
/// Note: This skips the backpressure mechanism with an unbounded
|
||||
/// channel. Use sparingly!
|
||||
pub fn send_action(&mut self, action: Action<T>)
|
||||
where
|
||||
T: std::fmt::Debug,
|
||||
{
|
||||
self.raw
|
||||
.send_event(Action::Output(value))
|
||||
.send_event(action)
|
||||
.expect("Send message to event loop");
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue