Class UnityUiShowModalParameters
Unity-specific implementation of parameters for showing modal dialogs.
Extends base UiShowModalParameters with Unity serialization support for button data.
Manages serialized button configurations for Unity Inspector and persistence systems.
Provides data integrity validation and ensures proper button list management.
Namespace: Serenity.Modal.InterfaceAdapters.EntityMappers
Assembly: Serenity.UnityModal.InterfaceAdapter.dll
Syntax
public class UnityUiShowModalParameters : UiShowModalParameters
Constructors
UnityUiShowModalParameters(string, string, string, string, string, UiComponentAlignmentType, IFoundationViewElementFactory, AudioPlayerPlayClip, string, IUiThemeSounds, List<SerializedComponentData>, bool, bool)
Initializes a new instance of UnityUiShowModalParameters with modal display configuration.
Sets up modal content, appearance settings, and button configurations for Unity UI system.
Handles serialized button data management and ensures proper initialization of button collections.
Declaration
public UnityUiShowModalParameters(string id, string guid, string signalTypeName, string title, string text, UiComponentAlignmentType alignment, IFoundationViewElementFactory foundationViewElementFactory, AudioPlayerPlayClip audioPlayerPlayClip, string audioServiceId, IUiThemeSounds themeSounds, List<SerializedComponentData> buttons, bool isTranslatingTitle = false, bool isTranslatingText = false)
Parameters
| Type | Name | Description |
|---|---|---|
| string | id | Unique identifier for the modal instance. |
| string | guid | Globally unique identifier for the modal. |
| string | signalTypeName | Type name of the event signal that triggers this modal. |
| string | title | Title text displayed at the top of the modal. |
| string | text | Main content text displayed in the modal body. |
| UiComponentAlignmentType | alignment | Alignment configuration for modal content elements. |
| IFoundationViewElementFactory | foundationViewElementFactory | Factory for creating UI foundation elements. |
| AudioPlayerPlayClip | audioPlayerPlayClip | Audio playback functionality for UI sounds. |
| string | audioServiceId | Identifier for the audio service instance. |
| IUiThemeSounds | themeSounds | Audio theme configuration for modal interactions. |
| List<SerializedComponentData> | buttons | List of serialized button component data for the modal. |
| bool | isTranslatingTitle | Whether the title is being translated. |
| bool | isTranslatingText | Whether the text content is being translated. |
Methods
EnsureInvariants()
Ensures data integrity and consistency for button parameter collections.
Initializes null button collections and maintains proper reference equality.
Should be called after deserialization or when parameter consistency needs to be validated.
Declaration
public void EnsureInvariants()
GetSignalInstance()
Declaration
public override EventDispatcherSignal GetSignalInstance()
Returns
| Type | Description |
|---|---|
| EventDispatcherSignal |