pub struct LocalEngine<M: TextEngine + 'static> { /* private fields */ }Expand description
An engine driven by its host’s event loop instead of a thread of its
own: the browser’s main thread in WebAssembly, where there are no
threads to block. Input sent through its EngineControl is handled
at the next LocalEngine::pump.
Implementations§
Source§impl<M: TextEngine + 'static> LocalEngine<M>
impl<M: TextEngine + 'static> LocalEngine<M>
Sourcepub fn start<S: MountSink>(
config: EngineConfig,
text_engine: M,
sink: S,
) -> Option<Self>
pub fn start<S: MountSink>( config: EngineConfig, text_engine: M, sink: S, ) -> Option<Self>
Starts the app (its first frame goes to sink before this returns);
None if it could not start (reported to sink).
Sourcepub fn control(&self) -> EngineControl
pub fn control(&self) -> EngineControl
A handle for sending input.
Auto Trait Implementations§
impl<M> !RefUnwindSafe for LocalEngine<M>
impl<M> !Send for LocalEngine<M>
impl<M> !Sync for LocalEngine<M>
impl<M> !UnwindSafe for LocalEngine<M>
impl<M> Freeze for LocalEngine<M>where
Driver<M>: Freeze,
impl<M> Unpin for LocalEngine<M>where
Driver<M>: Unpin,
impl<M> UnsafeUnpin for LocalEngine<M>where
Driver<M>: UnsafeUnpin,
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
Mutably borrows from an owned value. Read more