pub trait LayerState: Copy + Debug {
// Required methods
fn activate(&mut self, layer: LayerIndex, style: ActivationStyle);
fn deactivate(&mut self, layer: LayerIndex);
fn active_layers(&self) -> impl Iterator<Item = LayerIndex>;
}Expand description
Tracks state of active layers.
Required Methods§
Sourcefn activate(&mut self, layer: LayerIndex, style: ActivationStyle)
fn activate(&mut self, layer: LayerIndex, style: ActivationStyle)
Activate the given layer.
Sourcefn deactivate(&mut self, layer: LayerIndex)
fn deactivate(&mut self, layer: LayerIndex)
Deactivate the given layer.
Sourcefn active_layers(&self) -> impl Iterator<Item = LayerIndex>
fn active_layers(&self) -> impl Iterator<Item = LayerIndex>
Get the active layers, from highest active layer to lowest.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".