ProximitySensorDisplayOnOffController ProximitySensorDisplayOnOffController ProximitySensorDisplayOnOffController ProximitySensorDisplayOnOffController ProximitySensorDisplayOnOffController Class

Definition

Provides a controller responsible for turning on or off the phone display based on the readings from the ProximitySensor.

public : sealed class ProximitySensorDisplayOnOffController : IClosable
struct winrt::Windows::Devices::Sensors::ProximitySensorDisplayOnOffController : IClosable
public sealed class ProximitySensorDisplayOnOffController : IDisposable
Public NotInheritable Class ProximitySensorDisplayOnOffController Implements IDisposable
// This class does not provide a public constructor.
Attributes

Windows 10 requirements

Device family
Windows 10 (introduced v10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)

Remarks

This class will have no effect if your app is running on a platform that doesn't support a controller for the display state. For example, this class has no effect on applications running on a desktop because the desktop platform does not support a controller cycling the display.

Methods

Close() Close() Close() Close() Close()

Disconnects this ProximitySensorDisplayOnOffController instance from the service and frees all the allocated resources.

Dispose() Dispose() Dispose() Dispose() Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

See also