共用方式為


MapControl.MapContextRequested 事件

定義

發生于使用者在地圖上完成內容輸入手勢時,例如按一下滑鼠右鍵。

// Register
event_token MapContextRequested(TypedEventHandler<MapControl, MapContextRequestedEventArgs const&> const& handler) const;

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

// Revoke with event_revoker
MapControl::MapContextRequested_revoker MapContextRequested(auto_revoke_t, TypedEventHandler<MapControl, MapContextRequestedEventArgs const&> const& handler) const;
public event TypedEventHandler<MapControl,MapContextRequestedEventArgs> MapContextRequested;
function onMapContextRequested(eventArgs) { /* Your code */ }
mapControl.addEventListener("mapcontextrequested", onMapContextRequested);
mapControl.removeEventListener("mapcontextrequested", onMapContextRequested);
- or -
mapControl.onmapcontextrequested = onMapContextRequested;
Public Custom Event MapContextRequested As TypedEventHandler(Of MapControl, MapContextRequestedEventArgs) 

事件類型

Windows 需求

裝置系列
Windows 10 Creators Update (已於 10.0.15063.0 引進)
API contract
Windows.Foundation.UniversalApiContract (已於 v4.0 引進)

適用於