Skip to main content

next_phase

Function next_phase 

Source
pub fn next_phase(_current: SurfacePhase, event: SurfaceEvent) -> SurfacePhase
Expand description

Pure phase-transition table.

Transitions are total by design: Created always lands in SurfaceReady (creating or recreating), Destroyed always in NoSurface, and Lost always in SurfaceLost. Lost is only ever emitted from SurfaceReady (it originates in the render call), so no illegal edge is reachable in practice.