Windows Dev Center

DisplayPropertiesEventHandler delegate

[The DisplayProperties type and related event handlers may be altered or unavailable for releases after Windows 8.1. Instead, use DisplayInformation. ]

Represents a method that handles display property events.

Syntax


public delegate void DisplayPropertiesEventHandler(
  Object^ sender
)

Parameters

sender

Type: Object [JavaScript] | System.Object [.NET] | Platform::Object [C++]

The object that raised the event.

Remarks

We recommend that applications use a single delegate to handle most display events because in most cases the change to each display property requires that the application redraw itself. Also, many property changes result from a single mode change that affects the entire operating system.

The Direct3D 11.1 Simple Stereo 3D Sample shows how to handle system stereo changes.

Examples


void GameRenderer::Initialize(
)
{
DisplayProperties::StereoEnabledChanged += 
ref new DisplayPropertiesEventHandler(this, &GameRenderer::OnStereoEnableChanged);
}

void GameRenderer::OnStereoEnableChanged(
_In_ Platform::Object^ sender
)
{
UpdateForStereoChange();
}


Requirements (Windows 10 device family)

Device family

Universal

API contract

Windows.Foundation.UniversalApiContract, introduced version 1.0

Namespace

Windows.Graphics.Display
Windows::Graphics::Display [C++]

Metadata

Windows.Foundation.UniversalApiContract.winmd

Requirements (Windows 8.x and Windows Phone 8.x)

Minimum supported client

Windows 8

Minimum supported server

Windows Server 2012

Minimum supported phone

Windows Phone 8

Namespace

Windows.Graphics.Display
Windows::Graphics::Display [C++]

Metadata

Windows.winmd

Attributes

[Deprecated()]
[Version(0x06020000)]

 

 

Show:
© 2015 Microsoft