Window Framework for UI Toolkit v2.0.x
GWG.WindowFramework.Theming.PlayerThemeSelection Class Reference

Resolves stable identity without silently falling back to index zero or a palette. More...

Static Public Member Functions

static bool TryResolve (IReadOnlyList< WindowFrameTheme > builtIns, PlayerThemeCatalog players, string savedId, int legacyIndex, out string resolvedId, out string reason)
 Resolves saved identity or migrates a legacy index against built-in entries only.

Detailed Description

Resolves stable identity without silently falling back to index zero or a palette.

Member Function Documentation

◆ TryResolve()

bool GWG.WindowFramework.Theming.PlayerThemeSelection.TryResolve ( IReadOnlyList< WindowFrameTheme > builtIns,
PlayerThemeCatalog players,
string savedId,
int legacyIndex,
out string resolvedId,
out string reason )
inlinestatic

Resolves saved identity or migrates a legacy index against built-in entries only.

Parameters
builtInsConfigured shipped theme list, with saved stable IDs.
playersValidated live player catalog, or null when disabled.
savedIdSaved identity, empty for legacy migration.
legacyIndexPrevious index before player entries were appended.
resolvedIdSelected identity to persist.
reasonMigration/fallback explanation.
Returns
True when a valid configured selection exists.

Exactly one valid configured default is required. Caller persists the result only after successful UI application; this resolver does not write competing preferences.

Here is the caller graph for this function: