GameContainerView class final

The game surface: always full screen and transparent. It is presented only after the skin sends ready, so there is no loading state: the skin and the native close button animate in together (fade + scale 0.94→1, 240ms ease-out) and out on close (180ms ease-in) before the cover is removed. Taps pass through to the host app until the skin is ready; reduced motion removes the animation and the scale.

The rendered size is reported back as the viewport push whenever it changes (rotation, split screen); the safe area comes from the window. Port of iOS GameContainerView. Never throws from build.

Inheritance

Constructors

GameContainerView({required Widget child, required bool showMute, required bool isMuted, required VoidCallback onMuteToggled, required VoidCallback onClose, required GameSafeArea safeArea, required void onViewportChanged(double width, double height, GameSafeArea safeArea), bool isClosing = false, bool reducedMotion = false, bool ready = true, bool showClose = true, Key? key})
const

Properties

child → Widget
The full-size web view.
final
hashCode → int
The hash code for this object.
no setterinherited
isClosing → bool
final
isMuted → bool
final
key → Key?
Controls how one widget replaces another widget in the tree.
finalinherited
onClose → VoidCallback
final
onMuteToggled → VoidCallback
final
onViewportChanged → void Function(double width, double height, GameSafeArea safeArea)
final
ready → bool
Whether the skin sent ready. Before that the layer stays transparent and untouchable; on ready it fades in and starts taking taps.
final
reducedMotion → bool
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
safeArea → GameSafeArea
final
showClose → bool
Whether the native X shows; hiding it is opt-in. When false the close circle is hidden and a solo mute lands on its own 12dp offset. Port of Android/iOS showClose (absent=true).
final
showMute → bool
final

Methods

createElement() → StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() → State<GameContainerView>
Creates the mutable state for this widget at a given location in the tree.
override
debugDescribeChildren() → List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) → String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String
Returns a one-line detailed description of the object.
inherited
toStringShort() → String
A short, textual description of this widget.
inherited

Operators

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