SceneTransitionController class

Pure state machine driving SceneTransitionOverlay — no Animation/ BuildContext here, so it's unit-testable without pumping a widget tree.

Token-guarded: every run mints a new token and only that token's continuation is allowed to mutate phase/progress/lastError — a previous, still-in-flight run whose token has been superseded by a newer run (rapid re-navigation) silently drops its own late completion instead of stomping the newer transition's state. The same guard makes cancel and dispose immediately stop any in-flight run from mutating state further, so a load that finishes after cancel/dispose can never leave a stale pointer-blocking barrier up.

Constructors

SceneTransitionController({Duration coverDuration = const Duration(milliseconds: 260), Duration revealDuration = const Duration(milliseconds: 220)})

Properties

coverDuration → Duration
final
hashCode → int
The hash code for this object.
no setterinherited
isActive → bool
no setter
lastError ↔ SdkFailure<void>?
getter/setter pair
phase → Rx<SceneTransitionPhase>
final
progress → RxDouble
final
revealDuration → Duration
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

cancel() → void
Immediately drops back to idle and invalidates the active token — an in-flight run finishing later (success or failure) becomes a no-op.
dispose() → void
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
retry(SceneTransitionLoad load) → Future<SdkResult<void>>
run(SceneTransitionLoad load) → Future<SdkResult<void>>
runWithAssetPreload({required AssetPreloadCoordinator preload, required List<AssetManifestItem> manifest, GameSessionController? session}) → Future<SdkResult<void>>
Wires this controller's run to a real AssetPreloadCoordinator (FEAT-47) + GameSessionController (FEAT-41): preload's progress feeds this controller's progress, and a successful preload calls GameSessionController.markReady+GameSessionController.start so the session phase and the transition phase land in sync.
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited