3 instantiations of HwndSource
PresentationFramework (2)
System\Windows\Controls\Primitives\Popup.cs (1)
3359HwndSource newWindow = new HwndSource(param);
System\Windows\Window.cs (1)
2558HwndSource source = new HwndSource(param);
WindowsFormsIntegration (1)
System\Windows\Integration\ElementHost.cs (1)
583_hwndSource = new HwndSource(HWSParam);
180 references to HwndSource
PresentationCore (111)
MS\Internal\Automation\ElementUtil.cs (2)
166HwndSource hwndSource = HwndSource.CriticalFromHwnd(hwnd);
MS\Internal\Interop\TipTsfHelper.cs (2)
193private static HwndSource GetHwndSource(DependencyObject focusedObject) 195return PresentationSource.CriticalFromVisual(focusedObject) as HwndSource;
MS\Internal\WindowsRuntime\Windows\UI\ViewManagement\InputPane.cs (1)
138internal static InputPane GetForWindow(HwndSource source)
src\Microsoft.DotNet.Wpf\src\Shared\MS\Internal\PointUtil.cs (5)
170HwndSource inputSource = presentationSource as HwndSource; 192HwndSource inputSource = presentationSource as HwndSource; 273internal static Rect ClientToScreen(Rect rectClient, HwndSource hwndSource)
System\Windows\Automation\Peers\UIElement3DAutomationPeer.cs (2)
190HwndSource hwndSource = presentationSource as HwndSource;
System\Windows\Automation\Peers\UIElementAutomationPeer.cs (6)
193HwndSource hwndSource = presentationSource as HwndSource; 216HwndSource hwndSource = presentationSource as HwndSource; 510HwndSource hwndSource = presentationSource as HwndSource;
System\Windows\Diagnostics\VisualDiagnostics.cs (3)
39private static HwndSource s_ActiveHwndSource; 142HwndSource savedActiveHwndSource = s_ActiveHwndSource; 150s_ActiveHwndSource = PresentationSource.FromDependencyObject(args.Parent) as System.Windows.Interop.HwndSource;
System\Windows\DragDrop.cs (2)
1298HwndSource source; 1305source = HwndSource.FromHwnd(_windowHandle);
System\Windows\Input\AccessKeyManager.cs (2)
479return HwndSource.FromHwnd(hwnd); 488return HwndSource.CriticalFromHwnd(hwnd);
System\Windows\Input\InputElement.cs (4)
275HwndSource sourceFrom = PresentationSource.CriticalFromVisual(rootFrom) as HwndSource; 276HwndSource sourceTo = PresentationSource.CriticalFromVisual(rootTo) as HwndSource;
System\Windows\Input\MouseDevice.cs (4)
2078HwndSource source = inputSource as HwndSource; 2083HwndSource sourceHit = null ; 2097sourceHit = HwndSource.CriticalFromHwnd(hwndHit);
System\Windows\Input\Stylus\Common\StylusLogic.cs (2)
411var hwndSource = source as HwndSource;
System\Windows\Input\Stylus\Pointer\PointerStylusPlugInManager.cs (1)
71Matrix matrix = (_inputSource as HwndSource)?.CompositionTarget?.TransformToDevice ?? Matrix.Identity;
System\Windows\Input\Stylus\Wisp\PenContexts.cs (4)
38HwndSource hwndSource = inputSource as HwndSource; 558internal HwndSource InputSource => _inputSource; 562internal HwndSource _inputSource;
System\Windows\Input\Stylus\Wisp\WispLogic.cs (13)
647HwndSource hwndSource = mouseInputReport.InputSource as HwndSource; 2928HwndSource source = inputSource as HwndSource; 2933HwndSource sourceHit = null; 2943sourceHit = HwndSource.CriticalFromHwnd(hwndHit); 3129HwndSource hwndSource = (HwndSource)inputSource; 3179internal void UnRegisterHwndForInput(HwndSource hwndSource) 3254HwndSource hwndSource = mouseInputReport.InputSource as HwndSource; 3520HwndSource sourceHit = HwndSource.CriticalFromHwnd(hwnd);
System\Windows\Input\Stylus\Wisp\WispStylusDevice.cs (4)
1501HwndSource hwndSource = (HwndSource)inputSource; 1545HwndSource newHwndSource = HwndSource.CriticalFromHwnd(hwndHit);
System\Windows\InterOp\HwndAppCommandInputProvider.cs (2)
20internal HwndAppCommandInputProvider( HwndSource source ) 115private HwndSource _source;
System\Windows\InterOp\HwndKeyboardInputProvider.cs (15)
23internal HwndKeyboardInputProvider(HwndSource source) 217HwndSource._eatCharMessages = true; 218DispatcherOperation restoreCharMessages = Dispatcher.BeginInvoke(DispatcherPriority.Normal, new DispatcherOperationCallback(HwndSource.RestoreCharMessages), null); 234HwndSource._eatCharMessages = false; 273if(HwndSource._eatCharMessages) 356HwndSource hwndSource = PresentationSource.CriticalFromVisual(focusedDO) as HwndSource; 435HwndSource thisSource = _source; 482HwndSource hwndSource = PresentationSource.CriticalFromVisual(restoreFocusDO) as HwndSource; 505HwndSource hwndSource = PresentationSource.CriticalFromVisual(restoreFocusDO) as HwndSource; 743HwndSource hwndSource = HwndSource.CriticalFromHwnd(hwnd); 864private HwndSource _source;
System\Windows\InterOp\HwndMouseInputProvider.cs (11)
24internal HwndMouseInputProvider(HwndSource source) 218HwndSource inputSource = PresentationSource.FromDependencyObject(containingVisual) as HwndSource; 1027HwndSource hwndSource; 1050private bool HasCustomChrome(HwndSource hwndSource, ref NativeMethods.RECT rcClient) 1083private bool EnsureFrameworkAccessors(HwndSource hwndSource) 1125private Assembly GetPresentationFrameworkFromHwndSource(HwndSource hwndSource) 1180HwndSource hwndSource; 1184private bool IsOurWindowImpl(IntPtr hwnd, out HwndSource hwndSource) 1193hwndSource = HwndSource.CriticalFromHwnd(hwnd); 1459private HwndSource _source;
System\Windows\InterOp\HwndPanningFeedback.cs (2)
28public HwndPanningFeedback(HwndSource hwndSource) 135private HwndSource _hwndSource;
System\Windows\InterOp\HwndPointerInputProvider.cs (2)
33private readonly HwndSource _source; 72internal HwndPointerInputProvider(HwndSource source)
System\Windows\InterOp\HwndSource.cs (13)
671public static HwndSource FromHwnd(IntPtr hwnd) 676internal static HwndSource CriticalFromHwnd(IntPtr hwnd) 682HwndSource hwndSource = null; 685HwndSource test = source as HwndSource; 2083HwndSource mnemonicScope = (focusObject == null ? null : PresentationSource.CriticalFromVisual(focusObject) as HwndSource); 2705public WeakEventDispatcherShutdown(HwndSource source, Dispatcher that): base(source) 2713HwndSource source = this.Target as HwndSource; 2737public WeakEventPreprocessMessage(HwndSource source, bool addToFront): base(source) 2754HwndSource source = this.Target as HwndSource;
System\Windows\InterOp\HwndSourceKeyboardInputSite.cs (2)
20public HwndSourceKeyboardInputSite(HwndSource source, IKeyboardInputSink sink) 96private HwndSource _source;
System\Windows\InterOp\HwndSourceParameters.cs (1)
272get { return _acquireHwndFocusInMenuMode ?? HwndSource.DefaultAcquireHwndFocusInMenuMode; }
System\Windows\InterOp\HwndStylusInputProvider.cs (2)
36internal HwndStylusInputProvider(HwndSource source) 171private HwndSource _source;
System\Windows\InterOp\HwndTarget.cs (4)
882var hwndSource = HwndSource.FromHwnd(_hWnd); 923var hwndSource = HwndSource.FromHwnd(_hWnd);
PresentationFramework (62)
MS\Internal\Documents\DocumentViewerHelper.cs (2)
285HwndSource hwndSource = PresentationSource.CriticalFromVisual(findToolBar) as HwndSource;
System\Windows\Appearance\WindowBackdropManager.cs (4)
99var windowSource = HwndSource.FromHwnd(hwnd); 114var windowSource = HwndSource.FromHwnd(hwnd);
System\Windows\Automation\Peers\DocumentAutomationPeer.cs (4)
144HwndSource hwndSource = PresentationSource.CriticalFromVisual(uiScope) as HwndSource; 165HwndSource hwndSource = PresentationSource.CriticalFromVisual(uiScope) as HwndSource;
System\Windows\Automation\Peers\TextElementAutomationPeer.cs (4)
71HwndSource hwndSource = presentationSource as HwndSource; 113HwndSource hwndSource = presentationSource as HwndSource;
System\Windows\Controls\ComboBox.cs (2)
1943HwndSource source = PresentationSource.CriticalFromVisual(itemsHost) as HwndSource;
System\Windows\Controls\Menu.cs (2)
251System.Windows.Interop.HwndSource source = PresentationSource.CriticalFromVisual(this) as System.Windows.Interop.HwndSource;
System\Windows\Controls\PopupControlService.cs (2)
1611System.Windows.Interop.HwndSource hwndSource = _source as System.Windows.Interop.HwndSource;
System\Windows\Controls\Primitives\MenuBase.cs (2)
621HwndSource hwndSourceWithFocus = hwndWithFocus != IntPtr.Zero ? HwndSource.CriticalFromHwnd(hwndWithFocus) : null;
System\Windows\Controls\Primitives\Popup.cs (16)
2989HwndSource targetWindow = PopupSecurityHelper.GetPresentationSource(rootVisual) as HwndSource; 2999private NativeMethods.POINT ClientToScreen(HwndSource hwnd, Point clientPt) 3002HwndSource parent = null; 3005parent = HwndSource.CriticalFromHwnd(ParentHandle); 3030HwndSource hwndSource = null; 3033hwndSource = PopupSecurityHelper.GetPresentationSource(targetVisual) as HwndSource; 3125HwndSource hwndSource = null; 3128hwndSource = PopupSecurityHelper.GetPresentationSource(targetVisual) as HwndSource; 3311HwndSource hwndSource = PopupSecurityHelper.GetPresentationSource(mainTreeVisual) as HwndSource; 3359HwndSource newWindow = new HwndSource(param); 3400private static IntPtr GetHandle(HwndSource hwnd) 3406private static IntPtr GetParentHandle(HwndSource hwnd) 3464HwndSource hwnd = _window; 3484private HwndSource _window;
System\Windows\Documents\ImmComposition.cs (10)
63internal ImmComposition(HwndSource source) 81HwndSource source = PresentationSource.CriticalFromVisual(scope) as HwndSource; 272HwndSource newSource = null; 273HwndSource oldSource = null; 275newSource = e.NewSource as HwndSource; 276oldSource = e.OldSource as HwndSource; 293private void UpdateSource(HwndSource oldSource, HwndSource newSource) 1919private HwndSource _source;
System\Windows\Input\KeyboardNavigation.cs (3)
1219HwndSource hwndSource = keyEventArgs.UnsafeInputSource as HwndSource; 3295source = HwndSource.CriticalFromHwnd(activeWindow);
System\Windows\Interop\HwndHost.cs (2)
935HwndSource hwndSource = source as HwndSource ;
System\Windows\Shell\WindowChromeWorker.cs (3)
45private HwndSource _hwndSource = null; 156_hwndSource = HwndSource.FromHwnd(_hwnd); 175_hwndSource = HwndSource.FromHwnd(_hwnd);
System\Windows\Window.cs (6)
2340internal HwndSource HwndSourceWindow 2558HwndSource source = new HwndSource(param); 6944HwndSource source = _swh.HwndSourceWindow; 7404internal SourceWindowHelper( HwndSource sourceWindow ) 7533internal HwndSource HwndSourceWindow 7708private HwndSource _sourceWindow;
System.Windows.Controls.Ribbon (5)
Microsoft\Windows\Controls\Ribbon\Ribbon.cs (1)
1177if (e.OldSource is HwndSource &&
Microsoft\Windows\Controls\Ribbon\RibbonHelper.cs (4)
1007HwndSource hwndSource; 1008hwndSource = HwndSource.FromHwnd(hwnd); 2925HwndSource hwndSource = null; 2928hwndSource = PresentationSource.FromVisual(targetVisual) as HwndSource;
WindowsFormsIntegration (2)
System\Windows\Integration\ElementHost.cs (2)
48private HwndSource _hwndSource; 167internal HwndSource HwndSource