PowerManager.UserPresenceStatusChanged 이벤트
정의
중요
일부 정보는 릴리스되기 전에 상당 부분 수정될 수 있는 시험판 제품과 관련이 있습니다. Microsoft는 여기에 제공된 정보에 대해 어떠한 명시적이거나 묵시적인 보증도 하지 않습니다.
앱 세션과 연결된 사용자 상태가 변경되었을 때 발생합니다.
// Register
static event_token UserPresenceStatusChanged(EventHandler<IInspectable> const& handler) const;
// Revoke with event_token
static void UserPresenceStatusChanged(event_token const* cookie) const;
// Revoke with event_revoker
static PowerManager::UserPresenceStatusChanged_revoker UserPresenceStatusChanged(auto_revoke_t, EventHandler<IInspectable> const& handler) const;
public static event System.EventHandler<object> UserPresenceStatusChanged;
function onUserPresenceStatusChanged(eventArgs) { /* Your code */ }
Microsoft.Windows.System.Power.PowerManager.addEventListener("userpresencestatuschanged", onUserPresenceStatusChanged);
Microsoft.Windows.System.Power.PowerManager.removeEventListener("userpresencestatuschanged", onUserPresenceStatusChanged);
- or -
Microsoft.Windows.System.Power.PowerManager.onuserpresencestatuschanged = onUserPresenceStatusChanged;
Public Shared Custom Event UserPresenceStatusChanged As EventHandler(Of Object)
이벤트 유형
설명
이 이벤트에 대한 응답으로 현재 사용자 상태를 가져오려면 UserPresenceStatus 속성을 사용합니다. 이 이벤트는 GUID_SESSION_USER_PRESENCE전원 설정 GUID해당합니다.
적용 대상
추가 정보
- UserPresenceStatus
- UserPresenceStatus
- 앱 수명 주기 API 사용하여 전원 관리