ISystemBackdropControllerWithTargets.StateChanged 事件
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
当系统背景的状态发生更改时发生。
// Register
event_token StateChanged(TypedEventHandler<ISystemBackdropControllerWithTargets, IInspectable const&> const& handler) const;
// Revoke with event_token
void StateChanged(event_token const* cookie) const;
// Revoke with event_revoker
ISystemBackdropControllerWithTargets::StateChanged_revoker StateChanged(auto_revoke_t, TypedEventHandler<ISystemBackdropControllerWithTargets, IInspectable const&> const& handler) const;
event TypedEventHandler<ISystemBackdropControllerWithTargets,object> StateChanged;
function onStateChanged(eventArgs) { /* Your code */ }
iSystemBackdropControllerWithTargets.addEventListener("statechanged", onStateChanged);
iSystemBackdropControllerWithTargets.removeEventListener("statechanged", onStateChanged);
- or -
iSystemBackdropControllerWithTargets.onstatechanged = onStateChanged;
Event StateChanged As TypedEventHandler(Of ISystemBackdropControllerWithTargets, Object)
事件类型
TypedEventHandler<ISystemBackdropControllerWithTargets,Object>
TypedEventHandler<ISystemBackdropControllerWithTargets,IInspectable>
注解
可以订阅此事件,以便当 SystemBackdropState 在 和 Fallback
/High Contrast
之间Active
更改时收到通知。 例如,你可能想要根据系统背景材料状态更新其他非系统背景 UI。