共用方式為


GazeInputSourcePreview.GazeMoved 事件

定義

當眼球追蹤裝置偵測到眼球移動,而 注視指標 會保留在元素的周框內時發生。

// Register
event_token GazeMoved(TypedEventHandler<GazeInputSourcePreview, GazeMovedPreviewEventArgs const&> const& handler) const;

// Revoke with event_token
void GazeMoved(event_token const* cookie) const;

// Revoke with event_revoker
GazeInputSourcePreview::GazeMoved_revoker GazeMoved(auto_revoke_t, TypedEventHandler<GazeInputSourcePreview, GazeMovedPreviewEventArgs const&> const& handler) const;
public event TypedEventHandler<GazeInputSourcePreview,GazeMovedPreviewEventArgs> GazeMoved;
function onGazeMoved(eventArgs) { /* Your code */ }
gazeInputSourcePreview.addEventListener("gazemoved", onGazeMoved);
gazeInputSourcePreview.removeEventListener("gazemoved", onGazeMoved);
- or -
gazeInputSourcePreview.ongazemoved = onGazeMoved;
Public Custom Event GazeMoved As TypedEventHandler(Of GazeInputSourcePreview, GazeMovedPreviewEventArgs) 

事件類型

備註

此事件可能會引發許多事件。 請注意您放入處理常式之程式碼的效能設定檔,並考慮使用您自己的旗標或容錯的方式,以節流邏輯實際需要執行的次數。

適用於

另請參閱