logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Namespace Serenity.Ui.Infrastructure.Views

    Classes

    CompositeFocusRouter

    Owns a composite's input-focus model: which menu child currently holds input, cross-menu traversal between stacked menus (up/down at their first/last option, wrapping or stopping at the ends), the SWITCHER content-vs-nav-rail focus split, and the ancestor input-suppression gate. Extracted from UnityCompositeUiView so the focus rules are one plain, testable collaborator reading the composite's state through deferred providers; the view delegates its focus members here.

    HostedChildManager

    Owns the remount-on-show lifecycle of a composite's hosted children (shared view instances, e.g. menus): registration, mounting (reparent in + prepare) on show, releasing (restore + reparent back) on hide, and reacting to a mounted view re-measuring itself. Extracted from UnityCompositeUiView so the hosting rules are a single testable collaborator the factory wires up, rather than view internals.

    UnityCompositeUiView

    Focus wiring for UnityCompositeUiView. The focus model itself (focused child, cross-menu traversal, content-vs-nav-rail split, input gating) lives in CompositeFocusRouter; this partial delegates the view's focus members to it.

    UnityGameplayLoadingOverlayView

    Unity implementation of the gameplay loading overlay view. Renders a solid black fullscreen background and hosts a slider instance produced by the standard UI slider component factory, so the returned UnityUiSliderComponent is already fully initialized (parameters, actions, label localization, decorations). The overlay drives the bar via UnityEngine.UI.Slider.SetValueWithoutNotify(System.Single) and writes the "NN%" string through the component's built-in value placeholder. Reported progress is smoothed by a UnityLoadingOverlayProgressAnimator on the overlay root, and Hide() lets the bar visibly reach 100% before the overlay is destroyed.

    UnityLayoutBuilder

    Translates the engine-agnostic layout model (LayoutConfig / LayoutSize) onto Unity uGUI primitives — UnityEngine.UI.HorizontalLayoutGroup/UnityEngine.UI.VerticalLayoutGroup, UnityEngine.UI.LayoutElement, UnityEngine.UI.ContentSizeFitter and UnityEngine.UI.ScrollRect. This is the single place where CSS-style flexbox semantics become Unity layout components, keeping that mapping out of the domain and out of the composite view.

    UnityLoadingOverlayProgressAnimator

    Smooths the gameplay loading overlay's displayed progress toward the reported target so instantaneous progress jumps (e.g. a scene that loads in milliseconds) still render as a visible bar fill, and defers the overlay teardown until the bar has visibly reached 100%.

    UnityPercentLayoutElement

    Drives a UnityEngine.UI.LayoutElement's preferred size to a percentage of its parent's size along one axis, realizing the CSS % unit for a composite-view child. Unity's UnityEngine.UI.LayoutElement has no native percentage support, so this component recomputes the concrete pixel size whenever the parent's dimensions change.

    UnityPrimaryInputPromptView

    Unity implementation of primary input prompt view that handles initial player device detection and assignment.
    Provides two operational modes: gate-based detection using injected IPrimaryInputGate and self-armed detection using Unity Input System callbacks.
    Manages device pairing, control scheme switching, and player input routing for establishing the primary player interface.

    UnityScrollbarBuilder

    Builds a minimal, theme-independent scrollbar (translucent track + draggable handle) entirely in code, so any scrollable view can show scroll feedback without requiring an authored prefab. The bar is anchored as an overlay along the right edge (vertical) or bottom edge (horizontal) of its parent; callers may re-anchor the returned bar to span a specific region (e.g. a menu's visible options area).

    UnityUiView

    Abstract base class for Unity UI views providing common functionality for UI display and interaction.
    Manages view models, audio integration, event dispatching, and UI element lifecycle within the Unity UI system.
    Handles wrapper GameObject visibility, button state management, and audio playback coordination for consistent UI behavior.

    Interfaces

    IHostedSizeApplier

    Reserves a hosted view's reported content size on its layout slot. Implemented by UnityLayoutBuilder; injected into HostedChildManager (and used by the composite factory) so the "how an auto-sized hosted child claims space" rule has one owner instead of a static helper called from two places.

    In this article
    © 2026 Serenity. All Rights Reserved