public static void ReleasePointerCapture(this IInputElement element, IPointerDevice device) { if (element == device.Captured) { device.Capture(null); } }
public static bool CapturePointer(this IInputElement element, IPointerDevice device) { device.Capture(element); return(device.Captured == element); }