SpatialInteractionManager.SourcePressed 事件
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
發生于手部、動作控制器或語音來源進入按下狀態時。
// Register
event_token SourcePressed(TypedEventHandler<SpatialInteractionManager, SpatialInteractionSourceEventArgs const&> const& handler) const;
// Revoke with event_token
void SourcePressed(event_token const* cookie) const;
// Revoke with event_revoker
SpatialInteractionManager::SourcePressed_revoker SourcePressed(auto_revoke_t, TypedEventHandler<SpatialInteractionManager, SpatialInteractionSourceEventArgs const&> const& handler) const;
public event TypedEventHandler<SpatialInteractionManager,SpatialInteractionSourceEventArgs> SourcePressed;
function onSourcePressed(eventArgs) { /* Your code */ }
spatialInteractionManager.addEventListener("sourcepressed", onSourcePressed);
spatialInteractionManager.removeEventListener("sourcepressed", onSourcePressed);
- or -
spatialInteractionManager.onsourcepressed = onSourcePressed;
Public Custom Event SourcePressed As TypedEventHandler(Of SpatialInteractionManager, SpatialInteractionSourceEventArgs)
事件類型
備註
檢查 PressKind 以判斷按下的本質。