src\Microsoft.DotNet.Wpf\src\Shared\MS\Internal\PointUtil.cs (7)
33public static Point ClientToRoot(Point point, PresentationSource presentationSource)
39public static Point TryClientToRoot(Point point, PresentationSource presentationSource, bool throwOnError, out bool success)
65public static Point RootToClient(Point point, PresentationSource presentationSource)
164public static Point ClientToScreen(Point pointClient, PresentationSource presentationSource)
186internal static Point ScreenToClient(Point pointScreen, PresentationSource presentationSource)
221internal static Rect ElementToRoot(Rect rectElement, Visual element, PresentationSource presentationSource)
245internal static Rect RootToClient(Rect rectRoot, PresentationSource presentationSource)
System\Windows\Input\MouseDevice.cs (19)
119PresentationSource activeSource = CriticalActiveSource;
146PresentationSource activeSource = CriticalActiveSource;
167protected Point GetClientPosition(PresentationSource presentationSource)
199public override PresentationSource ActiveSource => _inputSource;
204internal PresentationSource CriticalActiveSource => _inputSource;
352PresentationSource captureSource = PresentationSource.CriticalFromVisual(containingVisual);
550PresentationSource relativePresentationSource = null;
559relativePresentationSource = PresentationSource.CriticalFromVisual(containingVisual);
793PresentationSource presentationSource = PresentationSource.CriticalFromVisual(visual);
879PresentationSource activeSource = CriticalActiveSource;
2077internal static IInputElement GlobalHitTest(bool clientUnits, Point pt, PresentationSource inputSource)
2086internal static IInputElement GlobalHitTest(Point ptClient, PresentationSource inputSource)
2094private static void GlobalHitTest(bool clientUnits, Point pt, PresentationSource inputSource, out IInputElement enabledHit, out IInputElement originalHit)
2132internal static IInputElement LocalHitTest(bool clientUnits, Point pt, PresentationSource inputSource)
2141internal static IInputElement LocalHitTest(Point ptClient, PresentationSource inputSource)
2148private static void LocalHitTest(bool clientUnits, Point pt, PresentationSource inputSource, out IInputElement enabledHit, out IInputElement originalHit)
2267private PresentationSource _inputSource;
System\Windows\PresentationSource.cs (28)
80public static PresentationSource FromVisual(Visual visual)
94public static PresentationSource FromDependencyObject(DependencyObject dependencyObject)
419PresentationSource oldSource = null;
429oldSource = (PresentationSource)oldRoot.GetValue(RootSourceProperty);
459PresentationSource testSource = (PresentationSource)element.GetValue(CachedSourceProperty);
529internal static PresentationSource CriticalFromVisual(DependencyObject v)
539internal static PresentationSource CriticalFromVisual(DependencyObject v, bool enable2DTo3DTransition)
543PresentationSource source = FindSource(v, enable2DTo3DTransition);
560PresentationSource ps = (PresentationSource)arg;
577PresentationSource baseSource = CriticalFromVisual(visuals[0]);
629element.SetValue(CachedSourceProperty, PresentationSource.FindSource(element));
644private static PresentationSource FindSource(DependencyObject o)
654private static PresentationSource FindSource(DependencyObject o, bool enable2DTo3DTransition)
656PresentationSource source = null;
665source = (PresentationSource)v.GetValue(RootSourceProperty);
676PresentationSource realSource = FindSource(doTarget);
677PresentationSource cachedSource = (PresentationSource)doTarget.GetValue(CachedSourceProperty);
722= DependencyProperty.RegisterAttached("RootSource", typeof(PresentationSource), typeof(PresentationSource),
723new PropertyMetadata((PresentationSource)null));
730= DependencyProperty.RegisterAttached("CachedSource", typeof(PresentationSource), typeof(PresentationSource),
731new PropertyMetadata((PresentationSource)null));
734private static readonly DependencyProperty GetsSourceChangedEventProperty = DependencyProperty.RegisterAttached("IsBeingWatched", typeof(bool), typeof(PresentationSource), new PropertyMetadata((bool)false));
739private static readonly RoutedEvent SourceChangedEvent = EventManager.RegisterRoutedEvent("SourceChanged", RoutingStrategy.Direct, typeof(SourceChangedEventHandler), typeof(PresentationSource));