Partager via


DisplayProperties.LogicalDpiChanged Événement

Définition

Notes

DisplayProperties peut être modifié ou indisponible pour les versions après Windows 8.1. Utilisez plutôt DisplayInformation.

Se produit lorsque la propriété LogicalDpi change, car les pixels par pouce (PPI) de l’affichage changent.

public:
 static event DisplayPropertiesEventHandler ^ LogicalDpiChanged;
/// [add: Windows.Foundation.Metadata.Deprecated("DisplayProperties may be altered or unavailable for releases after Windows Phone 8.1. Instead, use DisplayInformation.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, Windows.Foundation.UniversalApiContract)]
/// [remove: Windows.Foundation.Metadata.Deprecated("DisplayProperties may be altered or unavailable for releases after Windows Phone 8.1. Instead, use DisplayInformation.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, Windows.Foundation.UniversalApiContract)]
// Register
static event_token LogicalDpiChanged(DisplayPropertiesEventHandler const& handler) const;

// Revoke with event_token
static void LogicalDpiChanged(event_token const* cookie) const;

// Revoke with event_revoker
static DisplayProperties::LogicalDpiChanged_revoker LogicalDpiChanged(auto_revoke_t, DisplayPropertiesEventHandler const& handler) const;
/// [add: Windows.Foundation.Metadata.Deprecated("DisplayProperties may be altered or unavailable for releases after Windows Phone 8.1. Instead, use DisplayInformation.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, "Windows.Foundation.UniversalApiContract")]
/// [remove: Windows.Foundation.Metadata.Deprecated("DisplayProperties may be altered or unavailable for releases after Windows Phone 8.1. Instead, use DisplayInformation.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, "Windows.Foundation.UniversalApiContract")]
// Register
static event_token LogicalDpiChanged(DisplayPropertiesEventHandler const& handler) const;

// Revoke with event_token
static void LogicalDpiChanged(event_token const* cookie) const;

// Revoke with event_revoker
static DisplayProperties::LogicalDpiChanged_revoker LogicalDpiChanged(auto_revoke_t, DisplayPropertiesEventHandler const& handler) const;
[add: Windows.Foundation.Metadata.Deprecated("DisplayProperties may be altered or unavailable for releases after Windows Phone 8.1. Instead, use DisplayInformation.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, typeof(Windows.Foundation.UniversalApiContract))]
[remove: Windows.Foundation.Metadata.Deprecated("DisplayProperties may be altered or unavailable for releases after Windows Phone 8.1. Instead, use DisplayInformation.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, typeof(Windows.Foundation.UniversalApiContract))]
public static event DisplayPropertiesEventHandler LogicalDpiChanged;
[add: Windows.Foundation.Metadata.Deprecated("DisplayProperties may be altered or unavailable for releases after Windows Phone 8.1. Instead, use DisplayInformation.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, "Windows.Foundation.UniversalApiContract")]
[remove: Windows.Foundation.Metadata.Deprecated("DisplayProperties may be altered or unavailable for releases after Windows Phone 8.1. Instead, use DisplayInformation.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, "Windows.Foundation.UniversalApiContract")]
public static event DisplayPropertiesEventHandler LogicalDpiChanged;
function onLogicalDpiChanged(eventArgs) { /* Your code */ }
Windows.Graphics.Display.DisplayProperties.addEventListener("logicaldpichanged", onLogicalDpiChanged);
Windows.Graphics.Display.DisplayProperties.removeEventListener("logicaldpichanged", onLogicalDpiChanged);
- or -
Windows.Graphics.Display.DisplayProperties.onlogicaldpichanged = onLogicalDpiChanged;
Public Shared Custom Event LogicalDpiChanged As DisplayPropertiesEventHandler 

Type d'événement

Attributs

S’applique à