Struct ApplicationContext
The ApplicationContext provides the current context of the application.
Inherited Members
Namespace: UnityEngine.Dt.App.Core
Syntax
public struct ApplicationContext
Constructors
ApplicationContext(ApplicationContext, ContextProvider)
Construct an ApplicationContext based on an other one, and overrides from a given ContextProvider.
Declaration
public ApplicationContext(ApplicationContext context, ContextProvider contextProvider)
Parameters
Type | Name | Description |
---|---|---|
ApplicationContext | context | The reference application context. |
ContextProvider | contextProvider | The ContextProvider instance which overrides the reference application context. |
ApplicationContext(Panel)
Construct an ApplicationContext based on an Panel instance.
Declaration
public ApplicationContext(Panel app)
Parameters
Type | Name | Description |
---|---|---|
Panel | app | The application instance. |
Properties
closestProvider
The closest ContextProvider instance which overrides the current context.
Declaration
public readonly ContextProvider closestProvider { get; }
Property Value
Type | Description |
---|---|
ContextProvider |
lang
The current language.
Declaration
public readonly string lang { get; }
Property Value
Type | Description |
---|---|
String |
panel
The application instance which wraps the whole UI.
Declaration
public readonly Panel panel { get; }
Property Value
Type | Description |
---|---|
Panel |
preferredTooltipPlacement
The preferred placement of the tooltip.
Declaration
public readonly PopoverPlacement? preferredTooltipPlacement { get; }
Property Value
Type | Description |
---|---|
Nullable<PopoverPlacement> |
scale
The current scale of the UI. Possible values are "medium" or "large".
Declaration
public readonly string scale { get; }
Property Value
Type | Description |
---|---|
String |
theme
The current theme of the UI. Possible values are "dark" or "light".
Declaration
public readonly string theme { get; }
Property Value
Type | Description |
---|---|
String |