CoreApplicationViewTitleBar.LayoutMetricsChanged Event
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Occurs when the title bar needs to respond to size changes. The most common trigger for this event is when the app window moves to a screen that has a different DPI. Use this event to verify and update the positioning of UI elements that depend on the title bar's size.
// Register
event_token LayoutMetricsChanged(TypedEventHandler<CoreApplicationViewTitleBar, IInspectable const&> const& handler) const;
// Revoke with event_token
void LayoutMetricsChanged(event_token const* cookie) const;
// Revoke with event_revoker
CoreApplicationViewTitleBar::LayoutMetricsChanged_revoker LayoutMetricsChanged(auto_revoke_t, TypedEventHandler<CoreApplicationViewTitleBar, IInspectable const&> const& handler) const;
public event TypedEventHandler<CoreApplicationViewTitleBar,object> LayoutMetricsChanged;
function onLayoutMetricsChanged(eventArgs) { /* Your code */ }
coreApplicationViewTitleBar.addEventListener("layoutmetricschanged", onLayoutMetricsChanged);
coreApplicationViewTitleBar.removeEventListener("layoutmetricschanged", onLayoutMetricsChanged);
- or -
coreApplicationViewTitleBar.onlayoutmetricschanged = onLayoutMetricsChanged;
Public Custom Event LayoutMetricsChanged As TypedEventHandler(Of CoreApplicationViewTitleBar, Object)
Event Type
TypedEventHandler<CoreApplicationViewTitleBar,IInspectable>