Share via


DisplayState Class

Definition

Represents a slice in time of display pipeline state for a subset of the system's display targets. If IsReadOnly is false, then this object can be modified by connecting targets that are owned by the caller's DisplayManager, or by modifying path properties. Modifying a DisplayState object, or its child objects, does not directly modify the system's display state until you call TryApply.

public ref class DisplayState sealed
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 458752)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
class DisplayState final
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 458752)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
public sealed class DisplayState
Public NotInheritable Class DisplayState
Inheritance
Object Platform::Object IInspectable DisplayState
Attributes

Windows requirements

Device family
Windows 10, version 1809 (introduced in 10.0.17763.0)
API contract
Windows.Foundation.UniversalApiContract (introduced in v7.0)

Properties

IsReadOnly

Gets a value indicating whether this DisplayState and its child views and paths can be modified.

IsStale

Gets a value indicating whether the system display state has changed since this DisplayState was created.

Properties

Reserved for future use.

Targets

Returns the set of DisplayTarget objects used to create this DisplayState object.

Views

Gets a collection containing the views of the DisplayState.

Methods

CanConnectTargetToView(DisplayTarget, DisplayView)

Indicates whether or not the specified target can be connected to the specified view.

Clone()

Creates a copy of this DisplayState object, including copies of all views and paths.

ConnectTarget(DisplayTarget, DisplayView)

Connects the specified target to an existing logical clone group, and returns the resulting path.

ConnectTarget(DisplayTarget)

Connects the specified target, and returns the resulting path.

DisconnectTarget(DisplayTarget)

Disconnects the specified target.

GetPathForTarget(DisplayTarget)

Retrieves a DisplayPath object representing the specified target.

GetViewForTarget(DisplayTarget)

Retrieves a DisplayView object representing the view to which the target is connected.

TryApply(DisplayStateApplyOptions)

Attempts to atomically apply this DisplayState to the relevant hardware. Implicitly, this involves "functionalizing" all paths to determine the best modes matching all DisplayPath and DisplayView properties.

TryFunctionalize(DisplayStateFunctionalizeOptions)

Attempts to "functionalize" this DisplayState by trying to evaluate the best modes on all paths given all specified DisplayPath properties as constraints. This method then (optionally, see Remarks) updates all DisplayPath and DisplayView properties with the results of the functionalization. In particular, all DisplayPath and DisplayView properties set to null will have their values computed and set.

Applies to