PointerRoutedEventArgs.GetCurrentPoint(UIElement) 方法

定义

检索 PointerPoint 对象,该对象提供有关与事件关联的指针的基本信息。

public:
 virtual ExpPointerPoint ^ GetCurrentPoint(UIElement ^ relativeTo) = GetCurrentPoint;
public:
 virtual PointerPoint ^ GetCurrentPoint(UIElement ^ relativeTo) = GetCurrentPoint;
ExpPointerPoint GetCurrentPoint(UIElement const& relativeTo);
PointerPoint GetCurrentPoint(UIElement const& relativeTo);
public ExpPointerPoint GetCurrentPoint(UIElement relativeTo);
public PointerPoint GetCurrentPoint(UIElement relativeTo);
function getCurrentPoint(relativeTo)
function getCurrentPoint(relativeTo)
Public Function GetCurrentPoint (relativeTo As UIElement) As ExpPointerPoint
Public Function GetCurrentPoint (relativeTo As UIElement) As PointerPoint

参数

relativeTo
UIElement

连接到同一对象树的任何 UIElement 派生对象。 若要指定相对于整体坐标系的对象,请使用 relativeTonull

返回

一个 PointerPoint 值,该值表示与此事件关联的指针点。 如果 null 作为 relativeTo 传递,则坐标位于整个窗口的引用框架中。 如果传递了除 以外的 nullrelativeTo 值,则坐标相对于 relativeTo 引用的对象。

适用于