1 write to _threadingContext
Microsoft.VisualStudio.LanguageServices (1)
ProjectSystem\VisualStudioWorkspaceImpl.cs (1)
124_threadingContext = exportProvider.GetExportedValue<IThreadingContext>();
29 references to _threadingContext
Microsoft.VisualStudio.LanguageServices (29)
ProjectSystem\VisualStudioWorkspaceImpl.cs (18)
139this, FileChangeWatcher, CheckForAddedFileBeingOpenMaybeAsync, RemoveProjectFromMaps, _threadingContext.DisposalToken); 154_updateUIContextJoinableTasks = new JoinableTaskCollection(_threadingContext.JoinableTaskContext); 171_threadingContext.ThrowIfNotOnUIThread(); 212await _threadingContext.JoinableTaskFactory.SwitchToMainThreadAsync(alwaysYield: true, _threadingContext.DisposalToken); 285var document = _threadingContext.JoinableTaskFactory.Run(() => CurrentSolution.GetDocumentAsync(documentId, includeSourceGenerated: true).AsTask()); 305if (!_threadingContext.JoinableTaskContext.IsOnMainThread) 357_threadingContext.ThrowIfNotOnUIThread(); 629var mappedChanges = _threadingContext.JoinableTaskFactory.Run(() => GetMappedTextChangesAsync(solutionChanges)); 923var dte = _threadingContext.JoinableTaskFactory.Run(() => _asyncServiceProvider.GetServiceAsync<SDTE, EnvDTE.DTE>(_threadingContext.DisposalToken)); 1069if (!_threadingContext.JoinableTaskContext.IsOnMainThread) 1179this._threadingContext.ThrowIfNotOnUIThread(); 1384_threadingContext.ThrowIfNotOnUIThread(); 1508_threadingContext.ThrowIfNotOnUIThread(); 1601_threadingContext.RunWithShutdownBlockAsync(async cancellationToken => 1623var joinableTask = _threadingContext.JoinableTaskFactory.RunAsync(() => UpdateUIContextAsync(language, cancellationToken)); 1635await _threadingContext.JoinableTaskFactory.SwitchToMainThreadAsync(alwaysYield: true, cancellationToken);
ProjectSystem\VisualStudioWorkspaceImpl.OpenFileTracker.cs (10)
96_workspace._threadingContext.ThrowIfNotOnUIThread(); 109_workspace._threadingContext.ThrowIfNotOnUIThread(); 131_workspace._threadingContext.ThrowIfNotOnUIThread(); 187_workspace._threadingContext.ThrowIfNotOnUIThread(); 258_workspace._threadingContext.ThrowIfNotOnUIThread(); 270_workspace._threadingContext.ThrowIfNotOnUIThread(); 292_workspace._threadingContext.ThrowIfNotOnUIThread(); 310_workspace._threadingContext.ThrowIfNotOnUIThread(); 359if (_workspace._threadingContext.JoinableTaskContext.IsOnMainThread) 393await _workspace._threadingContext.JoinableTaskFactory.SwitchToMainThreadAsync();
ProjectSystem\VisualStudioWorkspaceImpl_SourceGenerators.cs (1)
19_threadingContext.ThrowIfNotOnUIThread();