pub trait Plugin:
Send
+ Sync
+ 'static {
// Provided methods
fn name(&self) -> &'static str { ... }
fn on_resumed(&mut self, _context: &PluginContext) -> PluginResult { ... }
fn on_suspended(&mut self, _context: &PluginContext) -> PluginResult { ... }
fn on_shutdown(&mut self, _context: &PluginContext) -> PluginResult { ... }
}Expand description
Lifecycle hooks for platform plugins.
Provided Methods§
Sourcefn on_resumed(&mut self, _context: &PluginContext) -> PluginResult
fn on_resumed(&mut self, _context: &PluginContext) -> PluginResult
Called when the renderer creates or resumes its platform resources.
Sourcefn on_suspended(&mut self, _context: &PluginContext) -> PluginResult
fn on_suspended(&mut self, _context: &PluginContext) -> PluginResult
Called when the renderer suspends and releases platform resources.
Sourcefn on_shutdown(&mut self, _context: &PluginContext) -> PluginResult
fn on_shutdown(&mut self, _context: &PluginContext) -> PluginResult
Called when the renderer is shutting down.