Table of Contents

Class WidgetFactoryManager

Namespace
Bannerlord.UIExtenderEx.ResourceManager
Assembly
Bannerlord.UIExtenderEx.dll

Manages runtime registration of custom Gauntlet widget types and prefabs within WidgetFactory.

public static class WidgetFactoryManager
Inheritance
WidgetFactoryManager
Inherited Members

Methods

Create(string, XmlDocument)

public static WidgetPrefab? Create(string name, XmlDocument doc)

Parameters

name string
doc XmlDocument

Returns

WidgetPrefab

Create(XmlDocument)

public static WidgetPrefab? Create(XmlDocument doc)

Parameters

doc XmlDocument

Returns

WidgetPrefab

CreateAndRegister(string, XmlDocument)

public static void CreateAndRegister(string name, XmlDocument xmlDocument)

Parameters

name string
xmlDocument XmlDocument

Patch(Harmony)

public static void Patch(Harmony harmony)

Parameters

harmony Harmony

Register(string, Func<WidgetPrefab?>)

Registers a custom widget prefab factory delegate under name. Replaces vanilla prefabs or prior registrations, evicting cached instances for subsequent instantiations.

public static void Register(string name, Func<WidgetPrefab?> create)

Parameters

name string
create Func<WidgetPrefab>

Register(Type)

public static void Register(Type widgetType)

Parameters

widgetType Type

ReloadOnNextUse(IEnumerable<string>)

Evicts cached instances of the specified prefabs from factory caches, forcing the next instantiation to re-parse. Allows newly enabled extensions or modifications to take effect without restarting the application.

public static void ReloadOnNextUse(IEnumerable<string> prefabNames)

Parameters

prefabNames IEnumerable<string>

This page was last modified at 10/05/2026 13:34:58 +03:00 (UTC).

Commit Message
Author:    Vitalii Mikhailov
Commit:    f3b725a97c3f299c20e56b5f206e27142ec15edd
* Added C# Auto-Generated XML prefab compilation for patched and dynamic movies, matching vanilla UI performance

* Added name-based property binding fallback for ViewModel subtypes not declared on the parent
* Improved unparseable prefab error logging with name and file details
* Fixed game crash with 3-segment attribute paths
* Added Bannerlord.UIExtenderE...