Share via


ContextRequestedEventArgs 類別

定義

提供 CoNtextRequested 事件的事件資料。

public ref class ContextRequestedEventArgs sealed : RoutedEventArgs
/// [Windows.Foundation.Metadata.Activatable(65536, "Microsoft.UI.Xaml.WinUIContract")]
/// [Windows.Foundation.Metadata.ContractVersion(Microsoft.UI.Xaml.WinUIContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class ContextRequestedEventArgs final : RoutedEventArgs
[Windows.Foundation.Metadata.Activatable(65536, "Microsoft.UI.Xaml.WinUIContract")]
[Windows.Foundation.Metadata.ContractVersion(typeof(Microsoft.UI.Xaml.WinUIContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class ContextRequestedEventArgs : RoutedEventArgs
Public NotInheritable Class ContextRequestedEventArgs
Inherits RoutedEventArgs
繼承
Object Platform::Object IInspectable RoutedEventArgs ContextRequestedEventArgs
屬性

建構函式

ContextRequestedEventArgs()

初始化 CoNtextRequestedEventArgs 類別的新實例。

屬性

Handled

取得或設定值,這個值會將路由事件標示為已處理。 true的值 Handled 可防止事件路由上的大部分處理常式再次處理相同的事件。

OriginalSource

取得引發事件之 物件的參考。 這通常是控制項的範本部分,而不是在應用程式 UI 中宣告的專案。

(繼承來源 RoutedEventArgs)

方法

TryGetPosition(UIElement, Point)

取得指標位置的 x 和 Y 座標,選擇性地根據所提供 UIElement的座標原點進行評估。

適用於

另請參閱