70 references to Current
IdeBenchmarks (2)
InheritanceMargin\InheritanceMarginGlyphBenchmarks.cs (2)
162if (Application.Current == null) 190_wpfApp = Application.Current;
Microsoft.AspNetCore.Components.WebView.Wpf (1)
BlazorWebView.cs (1)
111 ComponentsDispatcher = new WpfDispatcher(Application.Current.Dispatcher);
Microsoft.CodeAnalysis.EditorFeatures.Wpf (3)
InlineRename\UI\Dashboard\RenameDashboard.xaml.cs (3)
185if (Application.Current != null && Application.Current.MainWindow != null) 187_rootDependencyObject = Application.Current.MainWindow;
PresentationFramework (63)
Microsoft\Win32\CommonDialog.cs (2)
86if (Application.Current != null) 88hwndOwner = Application.Current.ParkingHwnd;
MS\Internal\AppModel\AppSecurityManager.cs (1)
201if (Application.Current.MimeType != MimeType.Document)
MS\Internal\AppModel\OleCmdHelper.cs (10)
62if (Application.Current == null || Application.IsShuttingDown == true) 87bool enabled = (bool)Application.Current.Dispatcher.Invoke( 94if (Application.Current.MainWindow == null) 96IInputElement target = FocusManager.GetFocusedElement(Application.Current.MainWindow); 100target = (IInputElement)Application.Current.MainWindow; 111if (Application.Current == null || Application.IsShuttingDown == true) 116int hresult = (int)Application.Current.Dispatcher.Invoke( 143if (Application.Current.MainWindow == null) 145IInputElement target = FocusManager.GetFocusedElement(Application.Current.MainWindow); 149target = (IInputElement)Application.Current.MainWindow;
MS\Internal\AppModel\SecurityMgrSite.cs (2)
26if (Application.Current != null) 28Window curWindow = Application.Current.MainWindow;
MS\Internal\Helper.cs (2)
86Application app = Application.Current; 92object appResource = Application.Current.FindResourceInternal(keys[k]);
MS\Internal\Printing\Win32PrintDialog.cs (3)
60if ((System.Windows.Application.Current != null) && 61(System.Windows.Application.Current.MainWindow != null)) 64new System.Windows.Interop.WindowInteropHelper(System.Windows.Application.Current.MainWindow);
System\Windows\Controls\DataGridCheckBoxColumn.cs (2)
36baseStyle = Application.Current.FindResource(typeof(CheckBox)) as Style; 68baseStyle = Application.Current.FindResource(typeof(CheckBox)) as Style;
System\Windows\Controls\DocumentViewer.cs (3)
2209if (Application.Current != null && Application.Current.CheckAccess()) 2211wnd = Application.Current.MainWindow;
System\Windows\Controls\VirtualizingStackPanel.cs (1)
12058Application app = Application.Current;
System\Windows\Documents\TextStore.cs (1)
4705Application app = Application.Current;
System\Windows\FrameworkContentElement.cs (1)
73Application app = Application.Current;
System\Windows\FrameworkElement.cs (2)
129Application app = Application.Current; 1066Application app = Application.Current;
System\Windows\Interop\BrowserInteropHelper.cs (1)
69return Application.Current?.MimeType == MimeType.Markup;
System\Windows\Navigation\NavigationService.cs (4)
478if (Application.Current == null) 487INavigatorBase navigator = FindTargetInWindowCollection(Application.Current.WindowsInternal.Clone(), targetName); 493navigator = FindTargetInWindowCollection(Application.Current.NonAppWindowsInternal.Clone(), targetName); 3397get { return Application.Current; }
System\Windows\Shell\JumpList.cs (1)
441if (_application == Application.Current && _initializing == false)
System\Windows\Standard\Debug.cs (1)
366if (System.Windows.Application.Current.Dispatcher.CheckAccess())
System\Windows\SystemResources.cs (2)
1901lock (((ICollection)Application.Current.Resources).SyncRoot) 1910lock (((ICollection)Application.Current.Resources).SyncRoot)
System\Windows\ThemeManager.cs (20)
20bool useLightColors = GetUseLightColors(Application.Current.ThemeMode); 22FluentThemeState newFluentThemeState = new FluentThemeState(Application.Current.ThemeMode.Value, useLightColors); 26AddOrUpdateThemeResources(Application.Current.Resources, GetThemeDictionary(Application.Current.ThemeMode)); 29foreach (Window window in Application.Current.Windows) 85AddOrUpdateThemeResources(Application.Current.Resources, GetThemeDictionary(newThemeMode)); 87foreach (Window window in Application.Current.Windows) 120ThemeMode themeMode = GetThemeModeFromResourceDictionary(Application.Current.Resources); 122if (Application.Current.ThemeMode != themeMode) 124Application.Current.ThemeMode = themeMode; 154useLightColors = GetUseLightColors(Application.Current.ThemeMode); 200return Application.Current != null && LastIndexOfFluentThemeDictionary(Application.Current.Resources) != -1; 210if (Application.Current == null) 213IEnumerable<int> indices = FindAllFluentThemeResourceDictionaryIndices(Application.Current.Resources); 217Application.Current.Resources.MergedDictionaries.RemoveAt(index); 220foreach (Window window in Application.Current.Windows) 267bool useLightColors = GetUseLightColors(Application.Current.ThemeMode); 312if (Application.Current == null) 314return Application.Current.ThemeMode != ThemeMode.None;
System\Windows\Window.cs (4)
3685if (Application.Current.Dispatcher.Thread == Dispatcher.CurrentDispatcher.Thread) 4540if (Application.Current.Dispatcher.Thread == Dispatcher.CurrentDispatcher.Thread) 7219get {return System.Windows.Application.Current;} 7229return (Application.Current != null);
PresentationUI (1)
MS\Internal\Documents\DocumentApplicationDocumentViewer.cs (1)
191System.Windows.Application.Current.MainWindow);