37 instantiations of Thread
mscorlib (2)
system\applicationactivator.cs (1)
86Thread th = new Thread(new ThreadStart(NewThreadRunner));
system\threading\Tasks\ThreadPoolTaskScheduler.cs (1)
61Thread thread = new Thread(s_longRunningThreadWork);
PresentationCore (1)
Core\CSharp\System\Windows\Media\Imaging\BitmapDownload.cs (1)
88_thread = new Thread(new ThreadStart(DownloadThreadProc));
PresentationFramework (1)
src\Framework\MS\Internal\AppModel\XappLauncher.cs (1)
534Thread thread = new Thread(() => AssertApplicationRequirementsAsync(null));
System (8)
compmod\microsoft\win32\SystemEvents.cs (1)
579windowThread = new Thread(new ThreadStart(systemEvents.WindowThreadProc));
compmod\system\diagnostics\assertwrapper.cs (1)
264Thread t = new Thread(DoPopup);
net\System\Net\_TimerThread.cs (1)
624new Thread(new ThreadStart(ThreadProc)).Start();
net\System\Net\connectionpool.cs (1)
163m_AsyncThread = new Thread(new ThreadStart(AsyncThread));
services\monitoring\system\diagnosticts\Process.cs (1)
2857Thread executionThread = new Thread(threadStart);
sys\system\io\ports\SerialStream.cs (2)
769? new Thread(new ThreadStart(eventRunner.WaitForCommEvent)) 770: new Thread(new ThreadStart(eventRunner.SafelyWaitForCommEvent));
sys\system\Media\SoundPlayer.cs (1)
368copyThread = new Thread(new ThreadStart(this.WorkerThread));
System.Activities (1)
System\Activities\Debugger\ThreadWorkerController.cs (1)
132this.worker = new Thread(new ThreadStart(WorkerThreadProc));
System.AddIn (1)
System\Addin\Pipeline\ContractBase.cs (1)
178System.Threading.Thread unloaderThread = new System.Threading.Thread(threadDelegate);
System.Data (2)
fx\src\data\System\Data\ProviderBase\DbConnectionPool.cs (2)
1211Thread waitOpenThread = new Thread(WaitForPendingOpen); 1522Thread waitOpenThread = new Thread(WaitForPendingOpen);
System.Drawing (1)
commonui\System\Drawing\ImageAnimator.cs (1)
232animationThread = new Thread(new ThreadStart(AnimateImages50ms));
System.Management (7)
Instrumentation\EventSource.cs (1)
341Thread thread = new Thread(new ThreadStart(MTAWorkerThread2));
Instrumentation\Instrumentation.cs (1)
496cleanupThread = new Thread(new ThreadStart(Cleanup));
InteropClasses\WMIInterop.cs (5)
1985Thread thread = new Thread(new ThreadStart(WorkerThread)); 2384this.thread = new Thread ( new ThreadStart ( ThreadEntryPointMethodWithReturn ) ) ; 2399this.thread = new Thread ( new ThreadStart ( ThreadEntryPointMethodWithReturnAndParam ) ) ; 2414this.thread = new Thread ( new ThreadStart ( ThreadEntryPoint ) ) ; 2429this.thread = new Thread ( new ThreadStart ( ThreadEntryPointMethodWithParam ) ) ;
System.Messaging (1)
System\Messaging\Design\QueuePathDialog.cs (1)
380populateThread = new Thread(new ThreadStart(this.PopulateThread));
System.Runtime.Remoting (2)
channels\http\httpserverchannel.cs (1)
208_listenerThread = new Thread(t);
channels\ipc\ipcserverchannel.cs (1)
165_listenerThread = new Thread(t);
System.ServiceModel (2)
System\ServiceModel\Administration\WbemProvider.cs (1)
1063Thread thread = new Thread(new ThreadStart(job.Run));
System\ServiceModel\ComIntegration\DllHostInitializer.cs (1)
71pingThread = new Thread(PingProc);
System.Windows.Forms (2)
winforms\Managed\System\WinForms\Printing\PrintControllerWithStatusDialog.cs (1)
169thread = new Thread(new ThreadStart(Run));
winforms\Managed\System\WinForms\TrustManager.cs (1)
1077System.Threading.Thread thread = new System.Threading.Thread(new System.Threading.ThreadStart(ShowDialogWork));
System.Workflow.Runtime (4)
DebugEngine\DebugController.cs (1)
81Thread workerThread = new Thread(new ThreadStart(processSecurity.Initialize));
DebugEngine\DebugControllerThread.cs (1)
32this.controllerThread = new Thread(ControllerThreadFunction);
DebugEngine\ProgramPublisher.cs (2)
49Thread publisherThread = new Thread(PublisherThreadFunc); 92Thread unpublisherThread = new Thread(UnpublishThreadFunc);
UIAutomationClient (1)
MS\Internal\Automation\QueueProcessor.cs (1)
83_thread = new Thread(threadStart);
UIAutomationClientsideProviders (1)
MS\Internal\AutomationProxies\QueueProcessor.cs (1)
68Thread thread = new Thread(threadStart);
1075 references to Thread
ComSvcConfig (3)
Tool.cs (3)
902Thread.CurrentThread.CurrentUICulture = CultureInfo.CurrentUICulture.GetConsoleFallbackUICulture(); 905Thread.CurrentThread.CurrentUICulture.TextInfo.OEMCodePage)) 907Thread.CurrentThread.CurrentUICulture = new CultureInfo("en-US");
mscorlib (348)
system\appdomain.cs (1)
2107return Thread.GetDomain();
system\applicationactivator.cs (4)
86Thread th = new Thread(new ThreadStart(NewThreadRunner)); 96if (Thread.CurrentThread.GetApartmentState() != ApartmentState.Unknown && Thread.CurrentThread.GetApartmentState() != m_apt) 98Thread.CurrentThread.SetApartmentState(m_apt);
system\collections\hashtable.cs (13)
453Thread.BeginCriticalRegion(); 467Thread.EndCriticalRegion(); 691Thread.Sleep(1); // 1 means we are yeilding control to all threads, including low-priority ones. 760Thread.BeginCriticalRegion(); 768Thread.EndCriticalRegion(); 920Thread.BeginCriticalRegion(); 930Thread.EndCriticalRegion(); 962Thread.BeginCriticalRegion(); 969Thread.EndCriticalRegion(); 1008Thread.BeginCriticalRegion(); 1018Thread.EndCriticalRegion(); 1094Thread.BeginCriticalRegion(); 1110Thread.EndCriticalRegion();
system\cominterfaces.cs (1)
57[TypeLibImportClassAttribute(typeof(System.Threading.Thread))]
system\console.cs (1)
292System.Threading.Thread.MemoryBarrier();
system\convert.cs (2)
203return ChangeType(value, typeCode, Thread.CurrentThread.CurrentCulture); 322return ChangeType(value, conversionType, Thread.CurrentThread.CurrentCulture);
system\diagnostics\eventing\activitytracker.cs (1)
380appDomainID = System.Threading.Thread.GetDomainID();
system\diagnostics\eventing\eventsource.cs (1)
3124Thread.Sleep(15);
system\diagnostics\stacktrace.cs (4)
29private Thread targetThread; 68public StackFrameHelper(Thread target) 472public StackTrace(Thread targetThread, bool needFileInfo) 517private void CaptureStackTrace(int iSkip, bool fNeedFileInfo, Thread targetThread, Exception e)
system\environment.cs (2)
1274System.Threading.Thread.MemoryBarrier(); 1806return Thread.CurrentThread.ManagedThreadId;
system\globalization\culturedata.cs (3)
1214if (CultureInfo.UserDefaultUICulture.Name.Equals(Thread.CurrentThread.CurrentUICulture.Name)) 1401if (CultureInfo.UserDefaultUICulture.Name.Equals(Thread.CurrentThread.CurrentUICulture.Name)) 1524if (CultureInfo.UserDefaultUICulture.Name.Equals(Thread.CurrentThread.CurrentUICulture.Name))
system\globalization\cultureinfo.cs (8)
555System.Threading.Thread.MemoryBarrier(); 556m_createdDomainID = Thread.GetDomainID(); 718return Thread.CurrentThread.CurrentCulture; 756Thread.CurrentThread.CurrentCulture = value; 816return Thread.CurrentThread.CurrentUICulture; 854Thread.CurrentThread.CurrentUICulture = value; 1451System.Threading.Thread.MemoryBarrier(); 1561System.Threading.Thread.MemoryBarrier();
system\globalization\datetimeformatinfo.cs (1)
519System.Globalization.CultureInfo culture = System.Threading.Thread.CurrentThread.CurrentCulture;
system\globalization\datetimeparse.cs (1)
4383m_info = Thread.CurrentThread.CurrentCulture.CompareInfo;
system\globalization\numberformatinfo.cs (1)
467System.Globalization.CultureInfo culture = System.Threading.Thread.CurrentThread.CurrentCulture;
system\io\filestream.cs (3)
253Thread.MemoryBarrier(); 277Thread.MemoryBarrier(); 351Thread.MemoryBarrier();
system\io\filesystemenumerable.cs (2)
93threadId = Thread.CurrentThread.ManagedThreadId; 117if (threadId == Thread.CurrentThread.ManagedThreadId && state == 0)
system\io\isolatedstorage\isolatedstorage.cs (2)
575domain = Thread.GetDomain(); 629domain = Thread.GetDomain();
system\io\streamwriter.cs (1)
113Thread.MemoryBarrier();
system\io\textwriter.cs (1)
119return Thread.CurrentThread.CurrentCulture;
system\resources\resourcemanager.cs (2)
1291culture = Thread.CurrentThread.GetCurrentUICultureNoAppX(); 1387culture = Thread.CurrentThread.GetCurrentUICultureNoAppX();
system\runtime\compilerservices\TaskAwaiter.cs (1)
254(continuationTask != null ? continuationTask.Id : 0), System.Threading.Thread.GetDomainID());
system\runtime\interopservices\marshal.cs (3)
1157public static Thread GetThreadFromFiberCookie(int cookie) 1168private static extern Thread InternalGetThreadFromFiberCookie(int cookie); 1639Assembly[] aAssemblies = Thread.GetDomain().GetAssemblies();
system\runtime\interopservices\typelibconverter.cs (2)
137AppDomain currentDomain = Thread.GetDomain(); 233AppDomain currentDomain = Thread.GetDomain();
system\runtime\interopservices\windowsruntime\windowsruntimemarshal.cs (2)
1009Thread.SpinWait(20); // Wait a few dozen instructions to let another processor release lock. 1011Thread.Sleep(0); // Give up my quantum.
system\runtime\remoting\activationservices.cs (12)
81DomainSpecificRemotingData remData = Thread.GetDomain().RemotingData; 100BCLDebug.Trace("REMOTE","Starting up activation service ",Thread.CurrentContext); 256Context cliCtx = Thread.CurrentContext; 486Thread.CurrentContext); 593Thread.CurrentContext.GetClientContextChain(); 704replyMsg = Thread.CurrentThread.InternalCrossContextCallback( 724Thread.CurrentContext.GetServerContextChain().SyncProcessMessage(reqMsg); 848if (Thread.CurrentContext != Context.DefaultContext) 889DomainSpecificRemotingData remData = Thread.GetDomain().RemotingData; 906Thread.GetDomain().RemotingData.ActivationListener, 933DomainSpecificRemotingData remData = Thread.GetDomain().RemotingData; 952DomainSpecificRemotingData remData = Thread.GetDomain().RemotingData;
system\runtime\remoting\callcontext.cs (12)
44ExecutionContext ec = Thread.CurrentThread.GetMutableExecutionContext(); 56ExecutionContext ec = Thread.CurrentThread.GetMutableExecutionContext(); 67return Thread.CurrentThread.GetExecutionContextReader().LogicalCallContext.GetData(name); 75return Thread.CurrentThread.GetExecutionContextReader().IllogicalCallContext.GetData(name); 83return Thread.CurrentThread.GetExecutionContextReader().LogicalCallContext.Principal; 89Thread.CurrentThread. 99ExecutionContext.Reader ec = Thread.CurrentThread.GetExecutionContextReader(); 109ExecutionContext ec = Thread.CurrentThread.GetMutableExecutionContext(); 149ExecutionContext ec = Thread.CurrentThread.GetMutableExecutionContext(); 157ExecutionContext ec = Thread.CurrentThread.GetMutableExecutionContext(); 167LogicalCallContext lcc = Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext; 174LogicalCallContext lcc = Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext;
system\runtime\remoting\channelservices.cs (2)
83get { return Thread.GetDomain().RemotingData.ChannelServicesData.remoteCalls; } 84set { Thread.GetDomain().RemotingData.ChannelServicesData.remoteCalls = value; }
system\runtime\remoting\channelsinkstacks.cs (1)
448returnValue, outArgs, _msg.ArgCount, Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext, _msg);
system\runtime\remoting\context.cs (7)
117DomainSpecificRemotingData data = Thread.GetDomain().RemotingData; 201return Thread.GetDomain().GetDefaultContext(); 644Context currCtx = Thread.CurrentContext; 682Thread.CurrentContext.DoCallBackGeneric(targetCtxID, ctxDel); 693IMessage retMsg = Thread.CurrentContext.GetClientContextChain().SyncProcessMessage(msgCall); 791Thread.CurrentContext.MyLocalStore.SetData(slot, data); 798return Thread.CurrentContext.MyLocalStore.GetData(slot);
system\runtime\remoting\crossappdomainchannel.cs (9)
39get { return Thread.GetDomain().RemotingData.ChannelServicesData.xadmessageSink; } 40set { Thread.GetDomain().RemotingData.ChannelServicesData.xadmessageSink = value; } 107Thread.GetDomain().GetId(), 216(Thread.GetDomain().GetId() == _DomainID); 377LogicalCallContext lcc = Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext; 423Message.DebugOut("#### : changed to Server Domain :: "+ (Thread.CurrentContext.InternalContextID).ToString("X") ); 460retBuff = (byte[]) Thread.CurrentThread.InternalCrossContextCallback(null, 467Message.DebugOut("#### : changed back to Client Domain " + (Thread.CurrentContext.InternalContextID).ToString("X")); 646_callCtx = Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext;
system\runtime\remoting\crosscontextchannel.cs (13)
35get { return Thread.GetDomain().RemotingData.ChannelServicesData.xctxmessageSink; } 36set { Thread.GetDomain().RemotingData.ChannelServicesData.xctxmessageSink = value; } 152replyMsg = (IMessage) Thread.CurrentThread.InternalCrossContextCallback(srvID.ServerContext, s_xctxDel, args); 270args[2] = Thread.CurrentContext; 275msgCtrl = (IMessageCtrl) Thread.CurrentThread.InternalCrossContextCallback(srvCtx, xctxDel, args); 287Thread.CurrentContext, 372args[2] = Thread.CurrentContext; 377msgCtrl = (IMessageCtrl) Thread.CurrentThread.InternalCrossContextCallback(srvCtx, xctxDel, args); 425_callCtx = Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext; 460|| (_srvID.ServerContext == Thread.CurrentContext), 465Thread.CurrentContext.NotifyDynamicSinks( 476retMsg = (IMessage) Thread.CurrentThread.InternalCrossContextCallback(_oldCtx, xctxDel, args); 541Thread.CurrentThread.InternalCrossContextCallback(_srvID.ServerContext, xctxDel, args);
system\runtime\remoting\identityholder.cs (6)
82_cachedDefaultContext = Thread.GetDomain().GetDefaultContext(); 103get { return Thread.GetDomain().RemotingData.IDTableLock;} 113Thread.GetDomain().RemotingData.IDTableLock.IsWriterLockHeld, 282serverCtx = Thread.CurrentContext; 490Message.DebugOut("SetIdentity:: domainid: " + Thread.GetDomainID() + "\n"); 723"IdentityHolder.WeakenIdentity ",uri, " for context ", Thread.CurrentContext);
system\runtime\remoting\lease.cs (2)
357sponsorCallThread = Thread.CurrentThread.GetHashCode(); 470int thisThread = Thread.CurrentThread.GetHashCode();
system\runtime\remoting\leasemanager.cs (3)
43DomainSpecificRemotingData remotingData = Thread.GetDomain().RemotingData; 51DomainSpecificRemotingData remotingData = Thread.GetDomain().RemotingData; 70DomainSpecificRemotingData remotingData = Thread.GetDomain().RemotingData;
system\runtime\remoting\message.cs (12)
854+ Thread.CurrentThread.GetHashCode() 858+ Thread.CurrentThread.GetHashCode() 877LogicalCallContext callCtx = Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext; 2558_callContext = Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext; 2575_callContext = Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext; 4963_sourceCtxID = Thread.CurrentContext.InternalContextID; 4972Thread.GetContextInternal(_targetCtxID)); 4988_sourceCtxID = Thread.CurrentContext.InternalContextID; 5068Contract.Assert(Thread.CurrentContext.InternalContextID 5082Context ctx = Thread.GetContextInternal(_targetCtxID); 5090Thread.GetContextInternal(_targetCtxID)); 5154Thread.CurrentContext.InternalContextID == _targetCtxID,
system\runtime\remoting\realproxy.cs (8)
307SetStubData(this, Thread.CurrentContext.InternalContextID); 331if(iVal.Equals(Thread.CurrentContext.InternalContextID)) 594Thread.CurrentContext.IsThreadPoolAware); 637Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext.Merge( 815Thread currentThread = Thread.CurrentThread; 829Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext.PropagateIncomingHeadersToCallContext(retMsg); 937void ReturnCallContextToThread(Thread currentThread, IMessage retMsg, int msgFlags, LogicalCallContext currCtx)
system\runtime\remoting\remotingproxy.cs (6)
80Thread currentThread, 189if (CtorThread == Thread.CurrentThread.GetHashCode()) 251Thread currentThread = Thread.CurrentThread; 471CtorThread = Thread.CurrentThread.GetHashCode(); 514Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext.Clone();
system\runtime\remoting\remotingservices.cs (15)
102return(Thread.CurrentContext != serverID.ServerContext); 303Object configLock = Thread.GetDomain().RemotingData.ConfigLock; 430serverCtx = Thread.GetDomain().GetDefaultContext(); 874BCLDebug.Trace("REMOTE", "RemotingServices.Disconnect ", obj, " for context ", Thread.CurrentContext); 912" for context " + Thread.CurrentContext + 1062Message.DebugOut("Entering Wrap for context " + Thread.CurrentContext + "\n"); 1176Context currContext = Thread.CurrentContext; 1217currContext = Thread.CurrentContext; 1243currContext = Thread.CurrentContext; 1573envoySink = Thread.CurrentContext.CreateEnvoyChain(tpOrObject); 1839Thread.CurrentContext.AppDomain, 1844ServerIdentity si = (ServerIdentity)MarshalByRefObject.GetIdentity(Thread.CurrentContext.AppDomain); 1865return (ObjRef) Thread.CurrentThread.InternalCrossContextCallback(null, defCtxID, appDomainId, xctxDel, null); 2272domainId = Thread.GetDomain().GetId(); 2324serverCtx = Thread.CurrentContext;
system\runtime\remoting\serveridentity.cs (1)
255BCLDebug.Assert(Thread.CurrentContext==_srvCtx,
system\runtime\remoting\stackbuildersink.cs (4)
70LogicalCallContext lcc = Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext; 124LogicalCallContext latestCallContext = Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext; 153LogicalCallContext latestCallContext = Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext; 249LogicalCallContext latestCallContext = Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext;
system\runtime\remoting\synchronizeddispatch.cs (3)
711_ctx = Thread.CurrentContext; 712_callCtx = Thread.CurrentThread.GetMutableExecutionContext().LogicalCallContext; 797Thread.CurrentThread.InternalCrossContextCallback(_ctx, _xctxDel, new Object[] { this } );
system\runtime\remoting\terminatorsinks.cs (9)
200return Thread.CurrentContext.GetClientContextChain().SyncProcessMessage(reqMsg); 222msgCtrl = Thread.CurrentContext.GetClientContextChain().AsyncProcessMessage(reqMsg, replySink); 291Context ctx = Thread.CurrentContext; 341replyMsg = (IMessage) Thread.CurrentThread.InternalCrossContextCallback(Context.DefaultContext, xctxDel, args); 417Context cliCtx = Thread.CurrentContext; 449msgCtrl = (IMessageCtrl) Thread.CurrentThread.InternalCrossContextCallback(Context.DefaultContext, xctxDel, args); 498Thread.CurrentContext.NotifyDynamicSinks( 521retMsg = (IMessage) Thread.CurrentThread.InternalCrossContextCallback(_cliCtx, xctxDel, args); 589Context ctx = Thread.CurrentContext;
system\security\accesscontrol\privilege.cs (8)
40private static LocalDataStoreSlot tlsSlot = Thread.AllocateDataSlot(); 50private readonly Thread currentThread = Thread.CurrentThread; 460if ( !this.currentThread.Equals( Thread.CurrentThread )) 496this.tlsContents = Thread.GetData( tlsSlot ) as TlsContents; 501Thread.SetData( tlsSlot, this.tlsContents ); 591if ( !this.currentThread.Equals( Thread.CurrentThread )) 728Thread.SetData( tlsSlot, null );
system\security\claims\ClaimsPrincipal.cs (2)
126ClaimsPrincipal claimsPrincipal = Thread.CurrentPrincipal as ClaimsPrincipal; 132return new ClaimsPrincipal(Thread.CurrentPrincipal);
system\security\cryptography\passwordderivebytes.cs (1)
45System.Threading.Thread.MemoryBarrier();
system\security\cryptography\rfc2898derivebytes.cs (1)
290System.Threading.Thread.MemoryBarrier();
system\security\permissions\principalpermission.cs (1)
466principal = Thread.CurrentPrincipal;
system\security\principal\windowsidentity.cs (3)
771return SecurityContext.GetCurrentWI(Thread.CurrentThread.GetExecutionContextReader()); 778Thread currentThread = Thread.CurrentThread;
system\security\securitycontext.cs (12)
117Contract.Assert(currEC == Thread.CurrentThread.GetMutableExecutionContext(), "SecurityContextSwitcher used from another thread"); 126Contract.Assert(Thread.CurrentThread.GetExecutionContextReader().SecurityContext.IsSame(prevSC)); 297ExecutionContext ec = Thread.CurrentThread.GetMutableExecutionContext(); 308SecurityContext sc = Thread.CurrentThread.GetMutableExecutionContext().SecurityContext; 329return Thread.CurrentThread.GetExecutionContextReader().SecurityContext.IsFlowSuppressed(flags); 356ExecutionContext.Reader ec = Thread.CurrentThread.GetExecutionContextReader(); 365if (GetCurrentWI(Thread.CurrentThread.GetExecutionContextReader()) != null) 373Contract.Assert(GetCurrentWI(Thread.CurrentThread.GetExecutionContextReader()) == null); 416rData.scsw = SetSecurityContext(rData.sc, Thread.CurrentThread.GetExecutionContextReader().SecurityContext, modifyCurrentExecutionContext: true); 466ExecutionContext currEC = Thread.CurrentThread.GetMutableExecutionContext(); 557SecurityContext sc = SecurityContext.Capture(Thread.CurrentThread.GetExecutionContextReader(), ref stackMark); 657Contract.Assert(currentEC.IsSame(Thread.CurrentThread.GetExecutionContextReader()));
system\string.cs (2)
3340return Thread.GetDomain().GetOrInternString(str); 3352return Thread.GetDomain().IsStringInterned(str);
system\threading\CancellationTokenRegistration.cs (1)
86tokenSource.ThreadIDExecutingCallbacks != Thread.CurrentThread.ManagedThreadId) //the executingThreadID is not this threadID.
system\threading\CancellationTokenSource.cs (5)
666int myIndex = Thread.CurrentThread.ManagedThreadId % s_nLists; 730ThreadIDExecutingCallbacks = Thread.CurrentThread.ManagedThreadId; 804ThreadIDExecutingCallbacks = Thread.CurrentThread.ManagedThreadId; 833Thread.MemoryBarrier(); // for safety, prevent reorderings crossing this point and seeing inconsistent state. 859callback.CancellationTokenSource.ThreadIDExecutingCallbacks = Thread.CurrentThread.ManagedThreadId;
system\threading\compressedstack.cs (5)
381return Thread.CurrentThread.SetAppDomainStack((cs == null ? null:cs.CompressedStackHandle)); 389Thread.CurrentThread.RestoreAppDomainStack(appDomainStack); //Restore the previous AD Stack 395return Thread.CurrentThread.GetExecutionContextReader().SecurityContext.CompressedStack; 402Thread currentThread = Thread.CurrentThread;
system\threading\executioncontext.cs (23)
299internal Thread thread; 335Contract.Assert(Thread.CurrentThread == this.thread); 336Thread currentThread = this.thread; 395private Thread _thread; 401Thread currentThread = Thread.CurrentThread; 411Thread currentThread = Thread.CurrentThread; 429if (_thread != Thread.CurrentThread) 435if (Thread.CurrentThread.GetMutableExecutionContext() != _ec) 444if (!Thread.CurrentThread.GetExecutionContextReader().SecurityContext.IsSame(_sc)) 672return Thread.CurrentThread.GetExecutionContextReader().GetLocalValue(local); 678ExecutionContext current = Thread.CurrentThread.GetMutableExecutionContext(); 948Thread currentThread = Thread.CurrentThread; 991EstablishCopyOnWriteScope(Thread.CurrentThread, false, ref ecsw); 995static private void EstablishCopyOnWriteScope(Thread currentThread, bool knownNullWindowsIdentity, ref ExecutionContextSwitcher ecsw) 997Contract.Assert(currentThread == Thread.CurrentThread); 1035Thread currentThread = Thread.CurrentThread; 1182ExecutionContext ec = Thread.CurrentThread.GetMutableExecutionContext(); 1193return Thread.CurrentThread.GetExecutionContextReader().IsFlowSuppressed; 1236ExecutionContext.Reader ecCurrent = Thread.CurrentThread.GetExecutionContextReader();
system\threading\hostexecutioncontextmanager.cs (2)
209ExecutionContext currentExecutionContext = Thread.CurrentThread.GetMutableExecutionContext(); 250ExecutionContext executionContext = Thread.CurrentThread.GetMutableExecutionContext();
system\threading\interlocked.cs (1)
253Thread.MemoryBarrier();
system\threading\ManualResetEventSlim.cs (5)
598Thread.Yield(); 603Thread.SpinWait(4 << i); 608Thread.Sleep(1); 612Thread.Sleep(0); 619Thread.Yield();
system\threading\mutex.cs (8)
174Thread.BeginThreadAffinity(); 175Thread.BeginCriticalRegion(); 224Thread.EndCriticalRegion(); 225Thread.EndThreadAffinity(); 416Thread.EndCriticalRegion(); 417Thread.EndThreadAffinity(); 459Thread.BeginThreadAffinity(); 477Thread.EndThreadAffinity();
system\threading\SpinLock.cs (19)
164Thread.BeginCriticalRegion(); 263Thread.BeginCriticalRegion(); 285Thread.EndCriticalRegion(); 340Thread.BeginCriticalRegion(); 357Thread.EndCriticalRegion(); 385Thread.SpinWait((turn + i) * SPINNING_FACTOR * processFactor); 392Thread.BeginCriticalRegion(); 413Thread.EndCriticalRegion(); 435Thread.BeginCriticalRegion(); 455Thread.EndCriticalRegion(); 461Thread.Sleep(1); 465Thread.Sleep(0); 472Thread.Yield(); 520int m_newOwner = Thread.CurrentThread.ManagedThreadId; 543Thread.BeginCriticalRegion(); 560Thread.EndCriticalRegion(); 593Thread.EndCriticalRegion(); 629Thread.EndCriticalRegion(); 709return ((m_owner & (~LOCK_ID_DISABLE_MASK)) == Thread.CurrentThread.ManagedThreadId);
system\threading\SpinWait.cs (5)
67/// cref="System.Threading.Thread.SpinWait"/> method. 146Thread.Sleep(1); 150Thread.Sleep(0); 157Thread.Yield(); 174Thread.SpinWait(4 << m_count);
system\threading\synchronizationcontext.cs (3)
242ExecutionContext ec = Thread.CurrentThread.GetMutableExecutionContext(); 252return Thread.CurrentThread.GetExecutionContextReader().SynchronizationContext ?? GetThreadLocalContext(); 262return Thread.CurrentThread.GetExecutionContextReader().SynchronizationContextNoFlow ?? GetThreadLocalContext();
system\threading\Tasks\ConcurrentExclusiveSchedulerPair.cs (8)
357Contract.Assert(!m_threadProcessingMapping.ContainsKey(Thread.CurrentThread.ManagedThreadId), 359m_threadProcessingMapping[Thread.CurrentThread.ManagedThreadId] = ProcessingMode.ProcessingExclusiveTask; 377m_threadProcessingMapping.TryRemove(Thread.CurrentThread.ManagedThreadId, out currentMode); 406Contract.Assert(!m_threadProcessingMapping.ContainsKey(Thread.CurrentThread.ManagedThreadId), 408m_threadProcessingMapping[Thread.CurrentThread.ManagedThreadId] = ProcessingMode.ProcessingConcurrentTasks; 437m_threadProcessingMapping.TryRemove(Thread.CurrentThread.ManagedThreadId, out currentMode); 581if (isDefaultScheduler && taskWasPreviouslyQueued && !Thread.CurrentThread.IsThreadPoolThread) 591if (m_pair.m_threadProcessingMapping.TryGetValue(Thread.CurrentThread.ManagedThreadId, out currentThreadMode) &&
system\threading\Tasks\Task.cs (5)
986System.Threading.Thread.GetDomainID()); 3234this.Id, TplEtwProvider.TaskWaitBehavior.Synchronous, 0, System.Threading.Thread.GetDomainID()); 3369Thread.Yield(); 3373Thread.SpinWait(4 << i); 3609(Thread.CurrentThread.ThreadState == ThreadState.AbortRequested) ||
system\threading\Tasks\TaskContinuation.cs (1)
519(TaskScheduler.InternalCurrent == m_scheduler || Thread.CurrentThread.IsThreadPoolThread);
system\threading\Tasks\ThreadPoolTaskScheduler.cs (1)
61Thread thread = new Thread(s_longRunningThreadWork);
system\threading\Tasks\TPLETWProvider.cs (1)
757int appDomainID = System.Threading.Thread.GetDomainID();
system\threading\thread.cs (10)
202Thread.CurrentThread.m_CurrentCulture = args.CurrentValue; 211Thread.CurrentThread.m_CurrentUICulture = args.CurrentValue; 389if (this == Thread.CurrentThread) 402Contract.Assert(Thread.CurrentThread == this); 563Thread thread = Thread.CurrentThread; 819public static Thread CurrentThread { 823Contract.Ensures(Contract.Result<Thread>() != null); 830private static extern Thread GetCurrentThreadNative(); 1131static extern private bool nativeGetSafeCulture(Thread t, int appDomainId, bool isUI, ref CultureInfo safeCulture);
system\threading\threadabortexception.cs (1)
52get {return Thread.CurrentThread.AbortReason;}
system\threading\threadpool.cs (2)
876public readonly Random random = new Random(Thread.CurrentThread.ManagedThreadId); 1032Thread.SpinWait(1); // yield to processor
system\threading\volatile.cs (22)
39Thread.MemoryBarrier(); 52Thread.MemoryBarrier(); 64Thread.MemoryBarrier(); 76Thread.MemoryBarrier(); 89Thread.MemoryBarrier(); 101Thread.MemoryBarrier(); 114Thread.MemoryBarrier(); 158Thread.MemoryBarrier(); 171Thread.MemoryBarrier(); 183Thread.MemoryBarrier(); 209Thread.MemoryBarrier(); 223Thread.MemoryBarrier(); 235Thread.MemoryBarrier(); 246Thread.MemoryBarrier(); 257Thread.MemoryBarrier(); 269Thread.MemoryBarrier(); 280Thread.MemoryBarrier(); 292Thread.MemoryBarrier(); 341Thread.MemoryBarrier(); 353Thread.MemoryBarrier(); 364Thread.MemoryBarrier(); 389Thread.MemoryBarrier();
system\threading\waithandle.cs (2)
572Thread.EndCriticalRegion(); 573Thread.EndThreadAffinity();
PresentationCore (30)
Core\CSharp\System\Windows\Clipboard.cs (6)
85Thread.Sleep(OleRetryDelay); 178Thread.Sleep(OleRetryDelay); 448Thread.Sleep(OleRetryDelay); 595Thread.Sleep(OleRetryDelay); 604Thread.Sleep(OleFlushDelay); 785Thread.Sleep(OleRetryDelay);
Core\CSharp\System\Windows\Input\InputManager.cs (1)
181if(Thread.CurrentThread.GetApartmentState() != ApartmentState.STA)
Core\CSharp\System\Windows\Input\InputMethod.cs (1)
474Dispatcher dispatcher = Dispatcher.FromThread(Thread.CurrentThread);
Core\CSharp\System\Windows\Input\InputProcessorProfiles.cs (1)
78Debug.Assert(Thread.CurrentThread.GetApartmentState() == ApartmentState.STA, "Initialize called on MTA thread!");
Core\CSharp\System\Windows\Input\InputProcessorProfilesLoader.cs (1)
74Debug.Assert(Thread.CurrentThread.GetApartmentState() == ApartmentState.STA, "Load called on MTA thread!");
Core\CSharp\System\Windows\Input\TextServicesContext.cs (1)
63Debug.Assert(Thread.CurrentThread.GetApartmentState() == ApartmentState.STA, "SetDispatcherThreaad on MTA thread");
Core\CSharp\System\Windows\Interop\HwndSource.cs (3)
48_threadSlot = Thread.AllocateDataSlot(); 3071object obj = Thread.GetData(_threadSlot); 3075Thread.SetData(_threadSlot, data);
Core\CSharp\System\Windows\Media\Effects\BitmapEffect.cs (1)
65if (Thread.CurrentThread.GetApartmentState() != ApartmentState.STA)
Core\CSharp\System\Windows\Media\HostVisual.cs (2)
148Debug.Assert(target.Dispatcher.Thread == Thread.CurrentThread); 201Debug.Assert(_target.Dispatcher.Thread == Thread.CurrentThread);
Core\CSharp\System\Windows\Media\Imaging\BitmapDownload.cs (1)
542private static Thread _thread;
Core\CSharp\System\Windows\OleServicesContext.cs (12)
88oleServicesContext = (OleServicesContext)Thread.GetData(OleServicesContext._threadDataSlot); 96Thread.SetData(OleServicesContext._threadDataSlot, oleServicesContext); 122if (Thread.CurrentThread.GetApartmentState() != ApartmentState.STA) 141if (Thread.CurrentThread.GetApartmentState() != ApartmentState.STA) 160if (Thread.CurrentThread.GetApartmentState() != ApartmentState.STA) 181if (Thread.CurrentThread.GetApartmentState() != ApartmentState.STA) 200if (Thread.CurrentThread.GetApartmentState() != ApartmentState.STA) 234if (Thread.CurrentThread.GetApartmentState() != ApartmentState.STA) 251if (Thread.CurrentThread.GetApartmentState() != ApartmentState.STA) 277if (Thread.CurrentThread.GetApartmentState() != ApartmentState.STA) 307if (Thread.CurrentThread.GetApartmentState() != ApartmentState.STA) 361private static readonly LocalDataStoreSlot _threadDataSlot = Thread.AllocateDataSlot();
PresentationFramework (41)
src\Framework\Microsoft\Win32\CommonDialog.cs (3)
297if (_thread != Thread.CurrentThread) 424private Thread _thread = Thread.CurrentThread;
src\Framework\MS\Internal\AppModel\XappLauncher.cs (1)
534Thread thread = new Thread(() => AssertApplicationRequirementsAsync(null));
src\Framework\MS\Internal\Data\ClrBindingWorker.cs (2)
407if (Dispatcher.Thread == Thread.CurrentThread) 435if (Dispatcher.Thread == Thread.CurrentThread)
src\Framework\System\Windows\Controls\CalendarBlackoutDatesCollection.cs (3)
22private Thread _dispatcherThread; 34this._dispatcherThread = Thread.CurrentThread; 345return Thread.CurrentThread == this._dispatcherThread;
src\Framework\System\Windows\Controls\Grid.cs (3)
3146WeakReference tempDefinitionsWeakRef = (WeakReference)Thread.GetData(s_tempDefinitionsDataSlot); 3150Thread.SetData(s_tempDefinitionsDataSlot, new WeakReference(extData.TempDefinitions)); 3355private static readonly LocalDataStoreSlot s_tempDefinitionsDataSlot = Thread.AllocateDataSlot();
src\Framework\System\Windows\Controls\SelectedDatesCollection.cs (3)
25private Thread _dispatcherThread; 39this._dispatcherThread = Thread.CurrentThread; 475return Thread.CurrentThread == this._dispatcherThread;
src\Framework\System\Windows\Controls\SpellCheck.cs (1)
156new FrameworkPropertyMetadata(Thread.CurrentThread.CurrentCulture.TwoLetterISOLanguageName == "de" ? SpellingReform.Postreform : SpellingReform.PreAndPostreform,
src\Framework\System\Windows\Controls\WebBrowser.cs (2)
452HRESULT hr = scriptObjectEx.GetIDsOfNames(ref guid, names, 1, Thread.CurrentThread.CurrentCulture.LCID, dispids); 481Thread.CurrentThread.CurrentCulture.LCID,
src\Framework\System\Windows\Data\BindingExpression.cs (1)
2520if (Dispatcher.Thread == Thread.CurrentThread)
src\Framework\System\Windows\Data\BindingExpressionBase.cs (1)
447if (Dispatcher.Thread == Thread.CurrentThread)
src\Framework\System\Windows\Data\BindingGroup.cs (1)
1528if (Dispatcher.Thread == Thread.CurrentThread)
src\Framework\System\Windows\Documents\Speller.cs (1)
56Thread.CurrentThread.CurrentCulture;
src\Framework\System\windows\Documents\TextEditor.cs (3)
1396store = (TextEditorThreadLocalStore)Thread.GetData(_threadLocalStoreSlot); 1401Thread.SetData(_threadLocalStoreSlot, store); 2111private static LocalDataStoreSlot _threadLocalStoreSlot = Thread.AllocateDataSlot();
src\Framework\System\Windows\Documents\TextServicesHost.cs (4)
81Debug.Assert(Thread.CurrentThread.GetApartmentState() == ApartmentState.STA, "OnRegisterTextStore must be called on STA thread"); 86_thread = Thread.CurrentThread; 461if (_thread == Thread.CurrentThread || System.Environment.OSVersion.Version.Major >= 6) 509private Thread _thread;
src\Framework\System\Windows\Documents\TextStore.cs (1)
2300Invariant.Assert(Thread.CurrentThread == _textservicesHost.Dispatcher.Thread, "GrantLock called on bad thread!");
src\Framework\System\Windows\Documents\WinRTSpellerInterop.cs (1)
85_defaultCulture = InputLanguageManager.Current?.CurrentInputLanguage ?? Thread.CurrentThread.CurrentCulture;
src\Framework\System\Windows\Interop\ActiveXHost.cs (1)
113if (Thread.CurrentThread.ApartmentState != ApartmentState.STA)
src\Framework\System\Windows\Interop\DocobjHost.cs (3)
79_mainThread = Thread.CurrentThread; 92private Thread _mainThread; 1219if (Thread.CurrentThread == _mainThread)
src\Framework\System\Windows\Interop\DynamicScriptObject.cs (3)
615HRESULT hr = _scriptObject.GetIDsOfNames(ref guid, names, dispids.Length, Thread.CurrentThread.CurrentCulture.LCID, dispids); 667return _scriptObjectEx.InvokeEx(dispid, Thread.CurrentThread.CurrentCulture.LCID, flags, dp, out result, exInfo, BrowserInteropHelper.HostHtmlDocumentServiceProvider); 672return _scriptObject.Invoke(dispid, ref guid, Thread.CurrentThread.CurrentCulture.LCID, flags, dp, out result, exInfo, null);
src\Framework\System\Windows\Standard\Debug.cs (1)
340if (Thread.CurrentThread.GetApartmentState() != expectedState)
src\Framework\System\Windows\Standard\Verify.cs (1)
41if (Thread.CurrentThread.GetApartmentState() != requiredState)
src\Framework\System\Windows\SystemResources.cs (1)
1396Dispatcher dispatcher = isSysColorsOrSettingsChange ? null : Dispatcher.FromThread(System.Threading.Thread.CurrentThread);
SMSvcHost (1)
System\ServiceModel\Activation\MessageQueue.cs (1)
449Thread.Sleep(AppSettings.ListenerRegistrationRetryDelay);
System (72)
compmod\microsoft\win32\SystemEvents.cs (5)
47private static volatile Thread windowThread; 489throw new ArgumentException(SR.GetString(SR.InvalidLowBoundArgument, "interval", interval.ToString(System.Threading.Thread.CurrentThread.CurrentCulture), "0")); 562if (Thread.GetDomain().GetData(".appDomain") != null) { 572if (!UserInteractive || Thread.CurrentThread.GetApartmentState() == ApartmentState.STA) { 1574Thread.Sleep(1);
compmod\system\componentmodel\CultureInfoConverter.cs (6)
93CultureInfo currentUICulture = Thread.CurrentThread.CurrentUICulture; 96Thread.CurrentThread.CurrentUICulture = culture; 145Thread.CurrentThread.CurrentUICulture = currentUICulture; 174CultureInfo currentUICulture = Thread.CurrentThread.CurrentUICulture; 177Thread.CurrentThread.CurrentUICulture = culture; 189Thread.CurrentThread.CurrentUICulture = currentUICulture;
compmod\system\diagnostics\assertwrapper.cs (1)
264Thread t = new Thread(DoPopup);
compmod\system\diagnostics\DiagnosticsConfiguration.cs (1)
119System.Threading.Thread.Sleep(200);
compmod\system\diagnostics\TraceEventCache.cs (1)
106return Thread.CurrentThread.ManagedThreadId;
net\System\Net\_Connection.cs (3)
1530else if (Thread.CurrentThread.IsThreadPoolThread) 1595else if (Thread.CurrentThread.IsThreadPoolThread) 3574if (Thread.CurrentThread.IsThreadPoolThread)
net\System\Net\_LazyAsyncResult.cs (1)
520Thread.SpinWait(1);
net\System\Net\_SafeNetHandles.cs (1)
2533Thread.SpinWait(1);
net\System\Net\_TimerThread.cs (11)
306GlobalLog.Assert(m_Timers.Prev.Next == m_Timers, "TimerThread#{0}::CreateTimer()|m_Tail corruption.", Thread.CurrentThread.ManagedThreadId.ToString()); 530GlobalLog.Assert(m_TimerState != TimerState.Sentinel, "TimerThread#{0}::Fire()|TimerQueue tried to Fire a Sentinel.", Thread.CurrentThread.ManagedThreadId.ToString()); 638GlobalLog.Print("TimerThread#" + Thread.CurrentThread.ManagedThreadId.ToString() + "::ThreadProc() Start"); 643Thread.CurrentThread.IsBackground = true; 703GlobalLog.Print("TimerThread#" + Thread.CurrentThread.ManagedThreadId.ToString() + "::ThreadProc() Waiting for " + waitDuration + "ms"); 708GlobalLog.Print("TimerThread#" + Thread.CurrentThread.ManagedThreadId.ToString() + "::ThreadProc() Awoke, cause: Shutdown"); 713GlobalLog.Print("TimerThread#" + Thread.CurrentThread.ManagedThreadId.ToString() + "::ThreadProc() Awoke, cause: " + (waitResult == WaitHandle.WaitTimeout ? "Timeout" : "Prod")); 734if (Logging.On) Logging.PrintError(Logging.Web, "TimerThread#" + Thread.CurrentThread.ManagedThreadId.ToString(NumberFormatInfo.InvariantInfo) + "::ThreadProc() - Exception:" + exception.ToString()); 735GlobalLog.Print("TimerThread#" + Thread.CurrentThread.ManagedThreadId.ToString() + "::ThreadProc() exception: " + exception); 743Thread.Sleep(1000); 751GlobalLog.Print("TimerThread#" + Thread.CurrentThread.ManagedThreadId.ToString() + "::ThreadProc() Stop");
net\System\Net\connectionpool.cs (2)
70private Thread m_AsyncThread; 205Thread.Sleep(500);
net\System\Net\HttpListener.cs (1)
2731Thread.SpinWait(1);
net\System\Net\HttpWebRequest.cs (3)
1594Thread.SpinWait(1); 2258Thread.SpinWait(1); 3168Thread.MemoryBarrier();
net\System\Net\Internal.cs (1)
708IsAspNetServer = (Thread.GetDomain().GetData(".appDomain") != null);
net\System\Net\Logging.cs (1)
293threadId = (uint)Thread.CurrentThread.GetHashCode();
net\System\Net\ServicePointManager.cs (1)
710Thread.MemoryBarrier();
net\System\Net\Sockets\Socket.cs (3)
2958(Thread.CurrentThread.IsThreadPoolThread || SettingsSectionInternal.Section.AlwaysUseCompletionPortsForConnect || m_IsDisconnected); 5333(Thread.CurrentThread.IsThreadPoolThread || SettingsSectionInternal.Section.AlwaysUseCompletionPortsForAccept || m_IsDisconnected); 6255Thread.SpinWait(1);
regex\system\text\regularexpressions\RegexCompiler.cs (1)
3066private static LocalDataStoreSlot _moduleSlot = Thread.AllocateDataSlot();
services\monitoring\system\diagnosticts\PerformanceCounterLib.cs (2)
992System.Threading.Thread.Sleep(waitSleep); 1255System.Threading.Thread.Sleep(waitSleep);
services\monitoring\system\diagnosticts\Process.cs (2)
2855if( Thread.CurrentThread.GetApartmentState() != ApartmentState.STA) { 2857Thread executionThread = new Thread(threadStart);
services\monitoring\system\diagnosticts\ProcessManager.cs (1)
644Thread.Sleep(1);
services\monitoring\system\diagnosticts\SharedPerformanceCounter.cs (3)
186Thread.MemoryBarrier(); 531Thread.Sleep(1); 1607System.Threading.Thread.Sleep(waitSleep);
services\monitoring\system\diagnosticts\SharedUtils.cs (5)
156Thread.Sleep(0); 174Thread.BeginCriticalRegion(); 175Thread.BeginThreadAffinity(); 199Thread.EndThreadAffinity(); 200Thread.EndCriticalRegion();
sys\system\collections\concurrent\BlockingCollection.cs (1)
1765return Thread.CurrentThread.GetApartmentState() == ApartmentState.STA;
sys\system\collections\concurrent\ConcurrentBag.cs (5)
309list = new ThreadLocalList(Thread.CurrentThread); 319list = new ThreadLocalList(Thread.CurrentThread); 352currentList.m_ownerThread = Thread.CurrentThread; // the caller should acquire a lock to make this line thread safe 956internal Thread m_ownerThread; 965internal ThreadLocalList(Thread ownerThread)
sys\system\io\ports\SerialStream.cs (3)
768Thread eventLoopThread = LocalAppContextSwitches.DoNotCatchSerialStreamThreadExceptions 799Thread.MemoryBarrier(); 1831Thread.MemoryBarrier();
sys\system\Media\SoundPlayer.cs (1)
40private Thread copyThread = null;
sys\system\runtime\interopservices\handlecollector.cs (1)
88Thread.Sleep (10*gen_collect);
sys\system\threading\Barrier.cs (5)
352if (m_actionCallerID != 0 && Thread.CurrentThread.ManagedThreadId == m_actionCallerID) 453if (m_actionCallerID != 0 && Thread.CurrentThread.ManagedThreadId == m_actionCallerID) 648if (m_actionCallerID != 0 && Thread.CurrentThread.ManagedThreadId == m_actionCallerID) 790m_actionCallerID = Thread.CurrentThread.ManagedThreadId; 936if (m_actionCallerID != 0 && Thread.CurrentThread.ManagedThreadId == m_actionCallerID)
System.Activities (17)
System\Activities\Debugger\ThreadWorkerController.cs (1)
34Thread worker;
System\Activities\WorkflowApplication.cs (16)
314return this.isInHandler && this.handlerThreadId == Thread.CurrentThread.ManagedThreadId; 810Thread.MemoryBarrier(); 985this.handlerThreadId = Thread.CurrentThread.ManagedThreadId; 1895Thread.MemoryBarrier(); 2350Thread.MemoryBarrier(); 2721this.handlerThreadId = Thread.CurrentThread.ManagedThreadId; 2772this.handlerThreadId = Thread.CurrentThread.ManagedThreadId; 3782Thread.MemoryBarrier(); 4595Thread.MemoryBarrier(); 4999application.handlerThreadId = Thread.CurrentThread.ManagedThreadId; 5132instance.handlerThreadId = Thread.CurrentThread.ManagedThreadId; 5267instance.handlerThreadId = Thread.CurrentThread.ManagedThreadId; 5678Thread.MemoryBarrier(); 5690Thread.MemoryBarrier(); 5746Thread.MemoryBarrier(); 6028Thread.MemoryBarrier();
System.Activities.Presentation (5)
System.Activities.Presentation\System\Activities\Presentation\ErrorReporting.cs (1)
222Thread.Sleep(50);
System.Activities.Presentation\System\Activities\Presentation\RetriableClipboard.cs (3)
36Thread.Sleep(sleepTime); 58Thread.Sleep(sleepTime); 79Thread.Sleep(sleepTime);
System.Activities.Presentation\System\Activities\Presentation\View\VisualBasicEditor.xaml.cs (1)
1798Thread.Sleep(ValidationWaitTime);
System.AddIn (6)
System\Addin\Hosting\AddInStore.cs (2)
1054Thread.Sleep(500); 1117Thread.Sleep(500);
System\Addin\Pipeline\ContractBase.cs (4)
88System.Threading.Thread.MemoryBarrier(); 178System.Threading.Thread unloaderThread = new System.Threading.Thread(threadDelegate); 221Thread.Sleep(1 << wait); 227Thread.Sleep(1 << MaxAppDomainUnloadWaits);
System.Configuration (1)
System\Configuration\Internal\WriteFileContext.cs (1)
212Thread.Sleep( SAVING_RETRY_INTERVAL );
System.Core (31)
System\Diagnostics\Eventing\Reader\EventLogWatcher.cs (2)
116if (this.callbackThreadId != Thread.CurrentThread.ManagedThreadId) { 202this.callbackThreadId = Thread.CurrentThread.ManagedThreadId;
System\IO\BufferedStream2.cs (5)
101Thread.Sleep(1); 117Thread.BeginCriticalRegion(); 126Thread.EndCriticalRegion(); 139Thread.SpinWait(1); 155Thread.EndCriticalRegion();
System\IO\MemoryMappedFiles\MemoryMappedFile.cs (1)
519System.Threading.Thread.Sleep(waitSleep);
System\IO\MemoryMappedFiles\MemoryMappedView.cs (2)
204Thread.Sleep(pause); 212Thread.Sleep(0);
System\Linq\Enumerable.cs (2)
76threadId = Thread.CurrentThread.ManagedThreadId; 91if (threadId == Thread.CurrentThread.ManagedThreadId && state == 0) {
System\Linq\Parallel\Channels\AsynchronousChannel.cs (2)
208Thread.CurrentThread.ManagedThreadId); 222Thread.CurrentThread.ManagedThreadId);
system\threading\ReaderWriterLockSlim\ReaderWriterLockSlim.cs (17)
305Thread.BeginCriticalRegion(); 316Thread.EndCriticalRegion(); 467Thread.BeginCriticalRegion(); 479Thread.EndCriticalRegion(); 690Thread.BeginCriticalRegion(); 701Thread.EndCriticalRegion(); 849Thread.EndCriticalRegion(); 869Thread.EndCriticalRegion(); 908Thread.EndCriticalRegion(); 922Thread.EndCriticalRegion(); 961Thread.EndCriticalRegion(); 974Thread.EndCriticalRegion(); 1311Thread.SpinWait(LockSpinCycles * spinCount); 1315Thread.Sleep(0); 1662Thread.SpinWait(LockSpinCycles * (spinIndex + 1)); // Wait a few dozen instructions to let another processor release lock. 1666Thread.Sleep(0); // Give up my quantum. 1670Thread.Sleep(1); // Give up my quantum.
System.Data (27)
cdf\src\NetFx40\Tools\System.Activities.Presentation\System\Activities\Presentation\ErrorReporting.cs (1)
222Thread.Sleep(50);
cdf\src\NetFx40\Tools\System.Activities.Presentation\System\Activities\Presentation\RetriableClipboard.cs (3)
36Thread.Sleep(sleepTime); 58Thread.Sleep(sleepTime); 79Thread.Sleep(sleepTime);
cdf\src\NetFx40\Tools\System.Activities.Presentation\System\Activities\Presentation\View\VisualBasicEditor.xaml.cs (1)
1798Thread.Sleep(ValidationWaitTime);
fx\src\data\System\Data\OleDb\OleDbConnectionInternal.cs (2)
687if (ApartmentState.Unknown == Thread.CurrentThread.GetApartmentState()) { 697Thread.CurrentThread.SetApartmentState(ApartmentState.MTA);
fx\src\data\System\Data\ProviderBase\DbConnectionFactory.cs (1)
320Threading.Thread.Sleep(timeBetweenRetriesMilliseconds);
fx\src\data\System\Data\ProviderBase\DbConnectionPool.cs (3)
1070Debug.Assert(!Thread.CurrentThread.IsThreadPoolThread, "This thread may block for a long time. Threadpool threads should not be used."); 1211Thread waitOpenThread = new Thread(WaitForPendingOpen); 1522Thread waitOpenThread = new Thread(WaitForPendingOpen);
fx\src\data\System\Data\SqlClient\SqlDependencyListener.cs (1)
835Thread.Sleep(1);
fx\src\data\System\Data\SqlClient\SqlInternalConnectionTds.cs (8)
435Thread.Sleep(transientRetryIntervalInMilliSeconds); 1650Thread.Sleep(sleepInterval); 1890Thread.Sleep(sleepInterval); 2469Thread.Sleep(sleepInterval); 2662return _threadIdOwningParserLock == Thread.CurrentThread.ManagedThreadId; 2666Debug.Assert(_threadIdOwningParserLock == -1 || _threadIdOwningParserLock == Thread.CurrentThread.ManagedThreadId, "Another thread already claims to own the parser lock"); 2670_threadIdOwningParserLock = Thread.CurrentThread.ManagedThreadId; 2672else if (_threadIdOwningParserLock == Thread.CurrentThread.ManagedThreadId) {
fx\src\data\System\Data\SqlClient\TdsParserStateObject.cs (5)
2014Thread.MemoryBarrier(); 2119Thread.MemoryBarrier(); 2577Thread.MemoryBarrier(); 2684Thread.MemoryBarrier(); 2931Thread.MemoryBarrier();
fx\src\data\System\Data\SQLTypes\SQLDateTime.cs (1)
356DateTimeFormatInfo dtfi = (DateTimeFormatInfo)(Thread.CurrentThread.CurrentCulture.GetFormat(typeof(DateTimeFormatInfo)));
fx\src\data\System\NewXml\XmlBoundElement.cs (1)
161System.Threading.Thread.Sleep(0);
System.Data.Linq (3)
SqlClient\Reader\ObjectReaderCompiler.cs (3)
149static LocalDataStoreSlot cacheSlot = Thread.AllocateDataSlot(); 190cache = (ReaderFactoryCache)Thread.GetData(cacheSlot); 193Thread.SetData(cacheSlot, cache);
System.Drawing (8)
commonui\System\Drawing\Advanced\Gdiplus.cs (5)
110LocalDataStoreSlot slot = Thread.GetNamedDataSlot(ThreadDataSlotName); 111IDictionary threadData = (IDictionary)Thread.GetData(slot); 114Thread.SetData(slot, threadData); 125LocalDataStoreSlot slot = Thread.GetNamedDataSlot(ThreadDataSlotName); 126Thread.SetData(slot, null);
commonui\System\Drawing\ImageAnimator.cs (2)
57static Thread animationThread; 371Thread.Sleep(50);
misc\HandleCollector.cs (1)
185System.Threading.Thread.Sleep(sleep);
System.IdentityModel (2)
System\IdentityModel\SecurityUtils.cs (2)
243Thread.MemoryBarrier(); 261Thread.MemoryBarrier();
System.IO.Log (2)
System\IO\Log\FileRecordSequence.cs (2)
479if (this.tailPinnedThreadID == Thread.CurrentThread.ManagedThreadId) 499this.tailPinnedThreadID = Thread.CurrentThread.ManagedThreadId;
System.Management (7)
Instrumentation\EventSource.cs (2)
195Thread.Sleep(50); 341Thread thread = new Thread(new ThreadStart(MTAWorkerThread2));
Instrumentation\Instrumentation.cs (2)
580Thread.Sleep(100); 601public Thread cleanupThread = null;
InteropClasses\WMIInterop.cs (3)
1985Thread thread = new Thread(new ThreadStart(WorkerThread)); 2100if(Thread.CurrentThread.GetApartmentState() != ApartmentState.MTA) 2182private Thread thread ;
System.Messaging (3)
System\Messaging\Design\QueuePathDialog.cs (1)
60private Thread populateThread = null;
System\Messaging\MessageQueue.cs (2)
1413Thread.MemoryBarrier(); 1436Thread.MemoryBarrier();
System.Runtime.Caching (4)
System\Caching\MemoryCache.cs (2)
183AppDomain appDomain = Thread.GetDomain(); 415AppDomain appDomain = Thread.GetDomain();
System\Caching\MemoryCacheStatistics.cs (2)
263Thread.Sleep(100); 295Thread.Sleep(100);
System.Runtime.Remoting (11)
channels\core\requestqueue.cs (1)
176Thread.Sleep(250);
channels\http\httpserverchannel.cs (1)
65private Thread _listenerThread;
channels\ipc\ipcserverchannel.cs (5)
51private Thread _listenerThread; 406oldPrincipal = Thread.CurrentPrincipal; 414Thread.CurrentPrincipal = new GenericPrincipal(identity, null); 423Thread.CurrentPrincipal = new WindowsPrincipal(identity); 443Thread.CurrentPrincipal = oldPrincipal;
channels\tcp\tcpserverchannel.cs (4)
566oldPrincipal = Thread.CurrentPrincipal; 570Thread.CurrentPrincipal = new WindowsPrincipal(identity); 575Thread.CurrentPrincipal = new GenericPrincipal(identity, null); 593Thread.CurrentPrincipal = oldPrincipal;
System.Runtime.Serialization (19)
System\Runtime\Serialization\ClassDataContract.cs (6)
130Thread.MemoryBarrier(); 282Thread.MemoryBarrier(); 309Thread.MemoryBarrier(); 1003Thread.MemoryBarrier(); 1132Thread.MemoryBarrier(); 1251Thread.MemoryBarrier();
System\Runtime\Serialization\CollectionDataContract.cs (5)
285Thread.MemoryBarrier(); 407Thread.MemoryBarrier(); 434Thread.MemoryBarrier(); 466Thread.MemoryBarrier(); 780Thread.MemoryBarrier();
System\Runtime\Serialization\EnumDataContract.cs (1)
328Thread.MemoryBarrier();
System\Runtime\Serialization\Json\JsonClassDataContract.cs (2)
48Thread.MemoryBarrier(); 71Thread.MemoryBarrier();
System\Runtime\Serialization\Json\JsonCollectionDataContract.cs (3)
45Thread.MemoryBarrier(); 77Thread.MemoryBarrier(); 100Thread.MemoryBarrier();
System\Runtime\Serialization\XmlDataContract.cs (2)
153Thread.MemoryBarrier(); 250Thread.MemoryBarrier();
System.Security (8)
system\security\cryptography\xml\utils.cs (8)
228Thread.MemoryBarrier(); 292Thread.MemoryBarrier(); 314Thread.MemoryBarrier(); 336Thread.MemoryBarrier(); 359Thread.MemoryBarrier(); 383Thread.MemoryBarrier(); 431Thread.MemoryBarrier(); 453Thread.MemoryBarrier();
System.ServiceModel (44)
System\ServiceModel\Activation\SharedMemory.cs (1)
60Thread.MemoryBarrier();
System\ServiceModel\Administration\WbemProvider.cs (2)
1059if (Thread.CurrentThread.GetApartmentState() != ApartmentState.MTA) 1063Thread thread = new Thread(new ThreadStart(job.Run));
System\ServiceModel\Channels\MessageHeaders.cs (1)
1198System.Threading.Thread.MemoryBarrier();
System\ServiceModel\Channels\Msmq4PoisonHandler.cs (1)
68if (Thread.CurrentThread.IsThreadPoolThread)
System\ServiceModel\Channels\MsmqReceiveHelper.cs (1)
39Thread.Sleep(TimeSpan.FromMilliseconds(MillisecondsToSleep));
System\ServiceModel\Channels\PipeConnection.cs (3)
2225if (!Thread.CurrentThread.IsThreadPoolThread) 2659Thread.MemoryBarrier(); 2702Thread.MemoryBarrier();
System\ServiceModel\Channels\ReliableChannelListener.cs (1)
773if (Thread.CurrentThread.IsThreadPoolThread)
System\ServiceModel\Channels\ReliableDuplexSessionChannel.cs (1)
1588if (Thread.CurrentThread.IsThreadPoolThread)
System\ServiceModel\Channels\ReliableMessagingHelpers.cs (1)
965else if (Thread.CurrentThread.IsThreadPoolThread)
System\ServiceModel\Channels\ReliableOutputSessionChannel.cs (1)
1015if (Thread.CurrentThread.IsThreadPoolThread)
System\ServiceModel\Channels\SecurityChannelListener.cs (1)
99System.Threading.Thread.MemoryBarrier();
System\ServiceModel\Channels\SharedHttpTransportManager.cs (1)
573if (Thread.CurrentThread.IsThreadPoolThread)
System\ServiceModel\Channels\SocketConnection.cs (2)
1809if (Thread.CurrentThread.IsThreadPoolThread) 2188if (!Thread.CurrentThread.IsThreadPoolThread)
System\ServiceModel\ComIntegration\ComPlusDiagnosticTraceRecords.cs (5)
199System.Threading.Thread.CurrentThread.ManagedThreadId, SafeNativeMethods.GetCurrentThreadId()); 233instanceID, System.Threading.Thread.CurrentThread.ManagedThreadId, SafeNativeMethods.GetCurrentThreadId(), callerIdentity, guidContextTrsansactionID); 239instanceID, System.Threading.Thread.CurrentThread.ManagedThreadId, SafeNativeMethods.GetCurrentThreadId(), callerIdentity); 251instanceID, System.Threading.Thread.CurrentThread.ManagedThreadId, SafeNativeMethods.GetCurrentThreadId(), callerIdentity, 262instanceID, System.Threading.Thread.CurrentThread.ManagedThreadId, SafeNativeMethods.GetCurrentThreadId(), callerIdentity,
System\ServiceModel\ComIntegration\ComPlusThreadInitializer.cs (2)
180System.Threading.Thread.CurrentThread.ManagedThreadId.ToString(CultureInfo.InvariantCulture), 240System.Threading.Thread.CurrentThread.ManagedThreadId.ToString(CultureInfo.InvariantCulture),
System\ServiceModel\ComIntegration\DllHostInitializer.cs (2)
41Thread.Sleep(10000); 67Thread pingThread = null;
System\ServiceModel\ComIntegration\EmitterCache.cs (2)
28Thread.MemoryBarrier(); 49assemblyBuilder = Thread.GetDomain().DefineDynamicAssembly(assemblyName, AssemblyBuilderAccess.Run);
System\ServiceModel\ComIntegration\OuterProxyWrapper.cs (1)
101Thread.MemoryBarrier();
System\ServiceModel\ComIntegration\TypeCacheManager.cs (1)
43Thread.MemoryBarrier();
System\ServiceModel\ComIntegration\TypeLibraryHelper.cs (1)
44Thread.MemoryBarrier();
System\ServiceModel\ComIntegration\WsdlServiceChannelBuilder.cs (2)
94Thread.MemoryBarrier(); 99Thread.MemoryBarrier();
System\ServiceModel\Description\ServiceMetadataExtension.cs (1)
252Thread.MemoryBarrier();
System\ServiceModel\Dispatcher\ChannelHandler.cs (1)
621if (Thread.CurrentThread.IsThreadPoolThread)
System\ServiceModel\Dispatcher\SecurityImpersonationBehavior.cs (3)
151result = Thread.CurrentPrincipal; 152Thread.CurrentPrincipal = principal; 320Thread.CurrentPrincipal = originalPrincipal;
System\ServiceModel\OperationContextScope.cs (3)
22readonly Thread thread = Thread.CurrentThread; 80if (ServiceModelAppSettings.DisableOperationContextAsyncFlow && this.thread != Thread.CurrentThread)
System\ServiceModel\Security\SecurityUtils.cs (1)
2349Thread.MemoryBarrier();
System\ServiceModel\Security\TlsSspiNegotiation.cs (1)
119Thread.Sleep(0);
System\ServiceModel\Transactions\WsatProxy.cs (1)
220Thread.Sleep(0);
System.ServiceModel.Activation (2)
System\ServiceModel\Activation\HostedHttpTransportManager.cs (2)
253Thread currentThread = Thread.CurrentThread;
System.ServiceModel.Activities (9)
System\ServiceModel\Activities\Dispatcher\WorkflowServiceInstance.cs (9)
279return this.isInHandler && this.handlerThreadId == Thread.CurrentThread.ManagedThreadId; 976Thread.MemoryBarrier(); 1245this.handlerThreadId = Thread.CurrentThread.ManagedThreadId; 1299this.handlerThreadId = Thread.CurrentThread.ManagedThreadId; 1345thisPtr.handlerThreadId = Thread.CurrentThread.ManagedThreadId; 1377thisPtr.handlerThreadId = Thread.CurrentThread.ManagedThreadId; 1419this.handlerThreadId = Thread.CurrentThread.ManagedThreadId; 1456thisPtr.handlerThreadId = Thread.CurrentThread.ManagedThreadId; 3872Thread.MemoryBarrier();
System.ServiceModel.Channels (4)
System\ServiceModel\Channels\UdpSocketReceiveManager.cs (4)
114if (Thread.CurrentThread.IsThreadPoolThread) 180Fx.Assert(Thread.CurrentThread.IsThreadPoolThread, "Receive loop is running on a non-threadpool thread. If this thread disappears while a completion port operation is outstanding, then the operation will get canceled."); 306if (StartAsyncReceive(socket) && !Thread.CurrentThread.IsThreadPoolThread) 316jumpThreads = !Thread.CurrentThread.IsThreadPoolThread;
System.ServiceModel.Internals (3)
System\Runtime\BackoffTimeoutHelper.cs (1)
97Thread.Sleep(WaitTimeWithDrift());
System\Runtime\SynchronizedPool.cs (2)
213int thisThreadID = Thread.CurrentThread.ManagedThreadId; 266int thisThreadID = Thread.CurrentThread.ManagedThreadId;
System.Transactions (27)
System\Transactions\Enlistment.cs (1)
301Thread.MemoryBarrier();
System\Transactions\Oletx\OletxEnlistment.cs (1)
741Thread.MemoryBarrier();
System\Transactions\Oletx\OletxResourceManager.cs (4)
50internal Thread reenlistThread; 167Thread.MemoryBarrier(); 692resourceManager.reenlistThread = Thread.CurrentThread; 1062Thread.MemoryBarrier();
System\Transactions\Oletx\OleTxTransaction.cs (2)
460Thread.MemoryBarrier(); 1420Thread.MemoryBarrier();
System\Transactions\Oletx\OletxTransactionManager.cs (4)
92Thread.BeginCriticalRegion(); 103Thread.BeginThreadAffinity(); 137Thread.EndThreadAffinity(); 504Thread.EndCriticalRegion();
System\Transactions\Transaction.cs (1)
1091Thread.MemoryBarrier();
System\Transactions\TransactionScope.cs (6)
608if ((this.scopeThread != Thread.CurrentThread) && !this.AsyncFlowEnabled) 1037this.scopeThread = Thread.CurrentThread; 1104if (this.scopeThread == Thread.CurrentThread) 1120if (this.savedCurrentScope.scopeThread != Thread.CurrentThread) 1141if (this.scopeThread != Thread.CurrentThread) 1430Thread scopeThread;
System\Transactions\TransactionTable.cs (8)
109Thread.Sleep( 0 ); 115Thread.Sleep( SLEEP_TIME ); 240Thread.BeginCriticalRegion(); 277Thread.EndCriticalRegion(); 513Thread.BeginCriticalRegion(); 558Thread.EndCriticalRegion(); 655Thread.MemoryBarrier(); // This data must be written before the transaction 697Thread.MemoryBarrier();
System.Web (177)
Cache\SqlCacheDependency.cs (3)
652Thread.Sleep(250); 807Thread.Sleep(250); 1028Thread.Sleep(250);
Compilation\BuildManager.cs (2)
2479Thread.Sleep(250); 2484Thread.Sleep(1000);
Compilation\BuildManagerHost.cs (3)
145Thread.Sleep(250); 580Thread.GetDomain().DomainUnload += _onAppDomainUnload; 599Thread.GetDomain().DomainUnload -= _onAppDomainUnload;
Compilation\BuildResultCache.cs (1)
943AppDomainSetup appDomainSetup = Thread.GetDomain().SetupInformation;
Compilation\ClientBuildManager.cs (1)
594Thread.Sleep(200);
Compilation\CodeDirectoryCompiler.cs (1)
186System.Threading.Thread.Sleep(250);
Configuration\ExpressServerConfig.cs (1)
35if (Thread.GetDomain().IsDefaultAppDomain()) {
Configuration\HttpCapabilitiesBase.cs (2)
553Thread.MemoryBarrier(); 878Thread.MemoryBarrier();
Configuration\serverconfig.cs (2)
44if (Thread.GetDomain().IsDefaultAppDomain() || (s_iisExpressVersion != null && s_iisExpressVersion != value )) 114if (!Thread.GetDomain().IsDefaultAppDomain()) {
FileChangesMonitor.cs (2)
2291Thread.Sleep(250); 2325Thread.Sleep(10);
Hosting\ApplicationManager.cs (2)
544Thread.Sleep(100); 1270System.Threading.Thread.Sleep(250);
Hosting\AsyncResultBase.cs (6)
26private Thread _threadWhichStartedOperation; 38if (Volatile.Read(ref _threadWhichStartedOperation) == Thread.CurrentThread) { 65Thread originalThread = Interlocked.CompareExchange(ref _threadWhichStartedOperation, Thread.CurrentThread, null); 70Thread originalThread = Interlocked.Exchange(ref _threadWhichStartedOperation, null); 71Debug.Assert(originalThread == Thread.CurrentThread, "This thread did not call MarkCallToBeginMethodStarted.");
Hosting\HostingEnvironment.cs (13)
190Thread.GetDomain().DomainUnload += _onAppDomainUnload; 195Thread.GetDomain().UnhandledException += new UnhandledExceptionEventHandler(ApplicationManager.OnUnhandledException); 235Thread.GetDomain().DomainUnload -= _onAppDomainUnload; 573Thread.Sleep(100); 719Thread.Sleep(100); 1818CultureInfo currentCulture = Thread.CurrentThread.CurrentCulture; 1819CultureInfo currentUICulture = Thread.CurrentThread.CurrentUICulture; 1822Thread.CurrentThread.CurrentCulture = culture; 1827Thread.CurrentThread.CurrentUICulture = uiCulture; 1833if (_savedCulture != null && _savedCulture != Thread.CurrentThread.CurrentCulture) { 1834Thread.CurrentThread.CurrentCulture = _savedCulture; 1838if (_savedUICulture != null && _savedUICulture != Thread.CurrentThread.CurrentUICulture) { 1839Thread.CurrentThread.CurrentUICulture = _savedUICulture;
Hosting\IIS7WorkerRequest.cs (1)
126if (EtwTrace.IsTraceEnabled(EtwTraceLevel.Verbose, EtwTraceFlags.Infrastructure)) EtwTrace.Trace(EtwTraceType.ETW_TYPE_APPDOMAIN_ENTER, this, Thread.GetDomain().FriendlyName);
Hosting\IPipelineRuntime.cs (9)
161Thread.MemoryBarrier(); 181Thread.MemoryBarrier(); 201Thread.MemoryBarrier(); 221Thread.MemoryBarrier(); 275Thread.Sleep(250); 553&& context.ThreadInsideIndicateCompletion != Thread.CurrentThread 556Thread.Sleep(10); 624context.ThreadInsideIndicateCompletion = Thread.CurrentThread; 712Thread.Sleep(250);
Hosting\ISAPIRuntime.cs (1)
192Thread.ResetAbort();
Hosting\ISAPIWorkerRequest.cs (3)
1055if (EtwTrace.IsTraceEnabled(EtwTraceLevel.Verbose, EtwTraceFlags.Infrastructure)) EtwTrace.Trace(EtwTraceType.ETW_TYPE_APPDOMAIN_ENTER, ecb, Thread.GetDomain().FriendlyName, null, false); 1069if (EtwTrace.IsTraceEnabled(EtwTraceLevel.Verbose, EtwTraceFlags.Infrastructure)) EtwTrace.Trace(EtwTraceType.ETW_TYPE_APPDOMAIN_ENTER, ecb, Thread.GetDomain().FriendlyName, null, true); 2091Thread.Sleep(250);
Hosting\SimpleWorkerRequest.cs (3)
381_appPhysPath = Thread.GetDomain().GetData(".appPath").ToString(); 382_appVirtPath = Thread.GetDomain().GetData(".appVPath").ToString(); 399if (Thread.GetDomain().GetData(".appPath") != null) {
HttpApplication.cs (14)
1236Thread.CurrentPrincipal = user; 2048_savedAppLevelCulture = Thread.CurrentThread.CurrentCulture; 2049_savedAppLevelUICulture = Thread.CurrentThread.CurrentUICulture; 2051if (culture != null && culture != Thread.CurrentThread.CurrentCulture) { 2055if (uiculture != null && uiculture != Thread.CurrentThread.CurrentUICulture) { 2056Thread.CurrentThread.CurrentUICulture = uiculture; 2061CultureInfo currentCulture = Thread.CurrentThread.CurrentCulture; 2062CultureInfo currentUICulture = Thread.CurrentThread.CurrentUICulture; 2076Thread.CurrentThread.CurrentUICulture = _savedAppLevelUICulture; 2233((Thread.CurrentThread.ThreadState & ThreadState.AbortRequested) == 0)) { 2270Thread.ResetAbort(); 2283if (Thread.CurrentThread.IsThreadPoolThread) { 4114if (context.InIndicateCompletion && context.ThreadInsideIndicateCompletion == Thread.CurrentThread) { 4281if (context.ThreadInsideIndicateCompletion == Thread.CurrentThread) {
HttpAsyncResult.cs (6)
27private Thread _threadWhichStartedOperation; 69if (Volatile.Read(ref _threadWhichStartedOperation) == Thread.CurrentThread) { 111Thread originalThread = Interlocked.CompareExchange(ref _threadWhichStartedOperation, Thread.CurrentThread, null); 116Thread originalThread = Interlocked.Exchange(ref _threadWhichStartedOperation, null); 117Debug.Assert(originalThread == Thread.CurrentThread, "This thread did not call MarkCallToBeginMethodStarted.");
HttpContext.cs (9)
108private Thread _thread; 153internal volatile Thread ThreadInsideIndicateCompletion = null; 173internal Thread _threadWhichStartedWebSocketTransition; 383_threadWhichStartedWebSocketTransition = Thread.CurrentThread; 389return _threadWhichStartedWebSocketTransition == Thread.CurrentThread; 1633internal Thread CurrentThread { 1767Thread.Sleep(100); 1774internal Thread MustTimeout(DateTime utcNow) { 1864Thread.ResetAbort();
HttpResponse.cs (4)
1187savedUiculture = Thread.CurrentThread.CurrentUICulture; 1188Thread.CurrentThread.CurrentUICulture = uiculture; 1233Thread.CurrentThread.CurrentUICulture = savedUiculture; 3115Thread.CurrentThread.Abort(new HttpApplication.CancelModuleException(false));
HttpRuntime.cs (15)
626CultureInfo savedCulture = Thread.CurrentThread.CurrentCulture; 627CultureInfo savedUICulture = Thread.CurrentThread.CurrentUICulture; 671Thread.CurrentThread.CurrentUICulture = savedUICulture; 706Thread.CurrentThread.CurrentCulture = cultureInfo; 871AppDomain appDomain = Thread.GetDomain(); 992_codegenDir = Thread.GetDomain().DynamicDirectory; 1000AppDomain appDomain = Thread.GetDomain(); 1335Thread.CurrentThread.CurrentUICulture = HttpServerUtility.CreateReadOnlyCultureInfo(globConfig.UICulture); 1886Thread.Sleep(250); 1892AppDomain.Unload(Thread.GetDomain()); 1947Thread.Sleep(250); 1998Thread.Sleep(250); 2184Thread.Sleep(250); 3069Object x = Thread.GetDomain().GetData(key); 3076AppDomain d = Thread.GetDomain();
httpserverutility.cs (1)
555Thread.Sleep(1);
Management\AppDomainResourcePerfCounters.cs (1)
55Thread.Sleep(100);
Management\SqlWebEventProvider.cs (1)
284Thread.Sleep(1000);
Management\WebEvents.cs (2)
1876_appDomain = Thread.GetDomain().FriendlyName; 2144_threadId = Thread.CurrentThread.ManagedThreadId;
ModelBinding\DataAnnotationsModelValidator.cs (1)
39.GetLocalizedString(Thread.CurrentThread.CurrentUICulture, name, arguments);
RequestQueue.cs (1)
274Thread.Sleep(100);
RequestTimeoutManager.cs (2)
57Thread.Sleep(100); 174Thread thread = _context.MustTimeout(now);
Security\AuthStoreRoleProvider.cs (1)
656IPrincipal user = Thread.CurrentPrincipal;
Security\BackStopAuthenticationModule.cs (1)
135Thread.CurrentPrincipal = context.User;
Security\Membership.cs (1)
595IPrincipal user = Thread.CurrentPrincipal;
Security\Roles.cs (1)
610return Thread.CurrentPrincipal;
Security\WindowsTokenRoleProvider.cs (1)
202IPrincipal user = Thread.CurrentPrincipal;
State\OutOfProcStateClientManager.cs (2)
120Thread.GetDomain().DomainUnload += s_onAppDomainUnload; 128Thread.GetDomain().DomainUnload -= s_onAppDomainUnload;
State\SessionStateContainer.cs (2)
175get { return Thread.CurrentThread.CurrentCulture.LCID; } 176set { Thread.CurrentThread.CurrentCulture = HttpServerUtility.CreateReadOnlyCultureInfo(value); }
State\sqlstateclientmanager.cs (4)
157Thread.GetDomain().DomainUnload += s_onAppDomainUnload; 166Thread.GetDomain().DomainUnload -= s_onAppDomainUnload; 855Thread.Sleep(FIRST_RETRY_SLEEP_TIME); 869Thread.Sleep(RETRY_SLEEP_TIME);
ThreadContext.cs (12)
90_originalThreadPrincipal = Thread.CurrentPrincipal; 101HttpContext.CurrentThread = Thread.CurrentThread; 253CultureInfo currentCulture = Thread.CurrentThread.CurrentCulture; 254CultureInfo currentUICulture = Thread.CurrentThread.CurrentUICulture; 272Thread.CurrentThread.CurrentUICulture = _originalThreadCurrentUICulture; 322_originalThreadCurrentCulture = Thread.CurrentThread.CurrentCulture; 323_originalThreadCurrentUICulture = Thread.CurrentThread.CurrentUICulture; 325if (culture != null && culture != Thread.CurrentThread.CurrentCulture) { 329if (uiculture != null && uiculture != Thread.CurrentThread.CurrentUICulture) { 330Thread.CurrentThread.CurrentUICulture = uiculture; 338HttpContext.DynamicCulture = Thread.CurrentThread.CurrentCulture; 339HttpContext.DynamicUICulture = Thread.CurrentThread.CurrentUICulture;
UI\BatchParser.cs (2)
47Thread currentThread = Thread.CurrentThread;
UI\LegacyPageAsyncTask.cs (1)
216Thread.ResetAbort();
UI\LegacyPageAsyncTaskManager.cs (2)
127Thread.Sleep(50); 333if (Thread.CurrentThread.IsThreadPoolThread) {
UI\Page.cs (13)
2571Thread.ResetAbort(); 3873Thread.CurrentThread.CurrentCulture = newCulture; 3877get { return Thread.CurrentThread.CurrentCulture.DisplayName; } 3891Thread.CurrentThread.CurrentCulture = newCulture; 3895get { return Thread.CurrentThread.CurrentCulture.LCID; } 3943Thread.CurrentThread.CurrentUICulture = newUICulture; 3947get { return Thread.CurrentThread.CurrentUICulture.DisplayName; } 4389void SetCultureWithAssert(Thread currentThread, CultureInfo currentCulture, CultureInfo currentUICulture) { 4393void SetCulture(Thread currentThread, CultureInfo currentCulture, CultureInfo currentUICulture) { 4409Thread currentThread = Thread.CurrentThread; 4509private void RestoreCultures(Thread currentThread, CultureInfo prevCulture, CultureInfo prevUICulture) { 5964if (Thread.CurrentThread.IsThreadPoolThread) {
UI\TemplateParser.cs (2)
679Thread currentThread = Thread.CurrentThread;
Util\AppVerifier.cs (5)
275Thread threadWhichCalledBeginHandler = Thread.CurrentThread; // used to determine whether the callback was invoked synchronously 294Thread tempThreadWhichCalledBeginHandler; 313assert(tempThreadWhichCalledBeginHandler != Thread.CurrentThread, AppVerifierErrorCode.AsyncCallbackInvokedSynchronouslyButAsyncResultWasNotMarkedCompletedSynchronously); 744ThreadId = Thread.CurrentThread.ManagedThreadId;
Util\AspCompat.cs (1)
385Thread.Sleep(1);
Util\FactoryGenerator.cs (1)
129Thread.GetDomain().DefineDynamicAssembly(assemblyName,
Util\FastPropertyAccessor.cs (1)
95Thread.GetDomain().DefineDynamicAssembly(assemblyName,
Util\ReadWriteSpinLock.cs (5)
95int threadId = Thread.CurrentThread.GetHashCode(); 109int threadId = Thread.CurrentThread.GetHashCode(); 289Thread.Sleep(sleepTime); 318Thread.Sleep(sleepTime); 348Thread.SpinWait(10);
Util\SynchronizationHelper.cs (6)
20private Thread _currentThread; // the Thread that's running the current Task; all threads must see the same value for this field 39private Thread CurrentThread { 76if (CurrentThread == Thread.CurrentThread) { 92CurrentThread = Thread.CurrentThread; 138if (CurrentThread == Thread.CurrentThread) { 154CurrentThread = Thread.CurrentThread;
System.Web.Extensions (41)
ApplicationServices\ApplicationServiceHelper.cs (1)
166return (context != null) ? context.User : Thread.CurrentPrincipal;
ClientServices\Providers\ClientFormsAuthenticationMembershipProvider.cs (16)
66Thread.CurrentPrincipal = new ClientRolePrincipal(new ClientFormsIdentity(username, password, 176UserValidated(this, new UserValidatedEventArgs(Thread.CurrentPrincipal.Identity.Name)); 184UserValidated(this, new UserValidatedEventArgs(Thread.CurrentPrincipal.Identity.Name)); 198IPrincipal p = Thread.CurrentPrincipal; 229Thread.CurrentPrincipal = new WindowsPrincipal(WindowsIdentity.GetCurrent()); 290if (Thread.CurrentPrincipal != null && Thread.CurrentPrincipal.Identity is ClientFormsIdentity) 291currentUser = Thread.CurrentPrincipal.Identity.Name; 300if ((Thread.CurrentPrincipal is ClientRolePrincipal) && (Thread.CurrentPrincipal.Identity is ClientFormsIdentity) && Thread.CurrentPrincipal.Identity.Name == username) 302cookies = ((ClientFormsIdentity)Thread.CurrentPrincipal.Identity).AuthenticationCookies; 355if ( !(Thread.CurrentPrincipal is ClientRolePrincipal) || !(Thread.CurrentPrincipal.Identity is ClientFormsIdentity) || Thread.CurrentPrincipal.Identity.Name != username) 359Thread.CurrentPrincipal = new ClientRolePrincipal(new ClientFormsIdentity(username, password, this, "ClientForms", true, cookies));
ClientServices\Providers\ClientRoleProvider.cs (1)
114IPrincipal p = Thread.CurrentPrincipal;
ClientServices\Providers\ClientSettingsProvider.cs (15)
77IIdentity id = Thread.CurrentPrincipal.Identity; 237_UserName = Thread.CurrentPrincipal.Identity.Name; 454ClientFormsIdentity id = Thread.CurrentPrincipal.Identity as ClientFormsIdentity; 471IIdentity id = Thread.CurrentPrincipal.Identity; 590ClientFormsIdentity id = Thread.CurrentPrincipal.Identity as ClientFormsIdentity; 627IIdentity id = Thread.CurrentPrincipal.Identity; 669ClientData cd = ClientDataManager.GetUserClientData(Thread.CurrentPrincipal.Identity.Name, _UsingIsolatedStore); 683using (DbConnection conn = SqlHelper.GetConnection(Thread.CurrentPrincipal.Identity.Name, 750string username = Thread.CurrentPrincipal.Identity.Name; 830ClientData cd = ClientDataManager.GetUserClientData(Thread.CurrentPrincipal.Identity.Name, _UsingIsolatedStore); 840ClientData cd = ClientDataManager.GetUserClientData(Thread.CurrentPrincipal.Identity.Name, _UsingIsolatedStore); 850ClientData cd = ClientDataManager.GetUserClientData(Thread.CurrentPrincipal.Identity.Name, _UsingIsolatedStore); 860ClientData cd = ClientDataManager.GetUserClientData(Thread.CurrentPrincipal.Identity.Name, _UsingIsolatedStore); 869string username = Thread.CurrentPrincipal.Identity.Name; 880string username = Thread.CurrentPrincipal.Identity.Name;
ClientServices\Providers\ClientWindowsAuthenticationMembershipProvider.cs (2)
35Thread.CurrentPrincipal = new ClientRolePrincipal(id); 40Thread.CurrentPrincipal = new WindowsPrincipal(WindowsIdentity.GetCurrent());
ClientServices\Providers\ProxyHelper.cs (2)
273if (Thread.CurrentPrincipal != null) 274username = Thread.CurrentPrincipal.Identity.Name;
UI\ScriptResourceAttribute.cs (3)
175CultureInfo previousCulture = Thread.CurrentThread.CurrentUICulture; 178Thread.CurrentThread.CurrentUICulture = culture; 211Thread.CurrentThread.CurrentUICulture = previousCulture;
UI\WebControls\Dynamic.cs (1)
298Thread.MemoryBarrier();
System.Web.Mobile (1)
UI\MobileControls\FactoryGenerator.cs (1)
143Thread.GetDomain().DefineDynamicAssembly(assemblyName,
System.Web.Services (5)
System\Web\Services\Configuration\WebServicesSection.cs (2)
66if (Thread.GetDomain().GetData(".appDomain") != null) { 169if (Thread.GetDomain().GetData(".appDomain") != null) {
System\Web\Services\Protocols\SoapHeader.cs (3)
209if (Thread.CurrentThread.GetHashCode() != this.currentThread) return; 217if (Thread.CurrentThread.GetHashCode() != this.currentThread) return; 239this.currentThread = Thread.CurrentThread.GetHashCode();
System.Windows.Forms (31)
misc\HandleCollector.cs (1)
185System.Threading.Thread.Sleep(sleep);
winforms\Managed\System\WinForms\Application.cs (9)
322return Thread.CurrentThread.CurrentCulture; 325Thread.CurrentThread.CurrentCulture = value; 1374current.idleHandler(Thread.CurrentThread, e); 2743enterModalHandler(Thread.CurrentThread, EventArgs.Empty); 2954leaveModalHandler(Thread.CurrentThread, EventArgs.Empty); 3179Thread current = Thread.CurrentThread; 3240threadExceptionHandler(Thread.CurrentThread, new ThreadExceptionEventArgs(t)); 3930idleHandler(Thread.CurrentThread, EventArgs.Empty);
winforms\Managed\System\WinForms\AxHost.cs (4)
2444return Thread.CurrentThread.CurrentCulture.LCID; 3734threadId = Thread.CurrentThread.ManagedThreadId; 3823if (threadId == Thread.CurrentThread.ManagedThreadId) { 3942if (connectionPoint.threadId == Thread.CurrentThread.ManagedThreadId) {
winforms\Managed\System\WinForms\Clipboard.cs (3)
183System.Threading.Thread.Sleep(retryDelay /*ms*/); 197System.Threading.Thread.Sleep(retryDelay /*ms*/); 251System.Threading.Thread.Sleep(retryDelay /*ms*/);
winforms\Managed\System\WinForms\ComponentModel\COM2Interop\COM2TypeInfoProcessor.cs (1)
50AppDomain currentDomain = Thread.GetDomain();
winforms\Managed\System\WinForms\Control.Ime.cs (1)
1366Debug.WriteLineIf(CompModSwitches.ImeMode.Level >= TraceLevel.Info, "Inside get_InputLanguageTable(), Input Language = " + InputLanguage.CurrentInputLanguage.Culture.DisplayName + ", Thread = " + System.Threading.Thread.CurrentThread.ManagedThreadId);
winforms\Managed\System\WinForms\FileDialog.cs (2)
636Thread.MemoryBarrier(); 667Thread.MemoryBarrier();
winforms\Managed\System\WinForms\FileDialog_Vista.cs (2)
165Thread.MemoryBarrier(); 198Thread.MemoryBarrier();
winforms\Managed\System\WinForms\Printing\PrintControllerWithStatusDialog.cs (1)
159private Thread thread;
winforms\Managed\System\WinForms\SendKeys.cs (1)
664System.Threading.Thread.Sleep(1);
winforms\Managed\System\WinForms\TrustManager.cs (1)
1077System.Threading.Thread thread = new System.Threading.Thread(new System.Threading.ThreadStart(ShowDialogWork));
winforms\Managed\System\WinForms\WindowsFormsSynchronizationContext.cs (5)
38DestinationThread = Thread.CurrentThread; //store the current thread to ensure its still alive during an invoke. 47private WindowsFormsSynchronizationContext(Control marshalingControl, Thread destinationThread) { 54private Thread DestinationThread { 57return destinationThreadRef.Target as Thread; 79Thread destinationThread = DestinationThread;
System.Workflow.Activities (5)
Executors\WorkflowWebService.cs (2)
182IIdentity identity = System.Threading.Thread.CurrentPrincipal.Identity; 206System.Threading.Thread.Sleep(500);
LocalService\CorrelationResolver.cs (1)
128System.Threading.Thread.MemoryBarrier();
LocalService\ExternalDataExchangeService.cs (1)
92String.Format(Thread.CurrentThread.CurrentCulture, SR.GetString(SR.Error_UnknownConfigurationParameter), key), "parameters");
LocalService\WorkflowMessageEventHandler.cs (1)
120IIdentity identity = System.Threading.Thread.CurrentPrincipal.Identity;
System.Workflow.ComponentModel (4)
AuthoringOM\ActivityExecutor.cs (3)
191System.Threading.Thread.MemoryBarrier(); 199System.Threading.Thread.MemoryBarrier(); 223System.Threading.Thread.MemoryBarrier();
AuthoringOM\Design\DesignerHelpers.cs (1)
1748string rulesText = (expression != null) ? expressionPropertyDescriptor.Converter.ConvertTo(new TypeDescriptorContext(activity.Site, null, value), System.Threading.Thread.CurrentThread.CurrentUICulture, expression, typeof(string)) as string : null;
System.Workflow.Runtime (19)
DbRetry.cs (1)
63Thread.Sleep(sleep);
DebugEngine\BreakSafeBase.cs (1)
44return Thread.CurrentThread.ManagedThreadId == this.controllerManagedThreadId;
DebugEngine\DebugController.cs (1)
81Thread workerThread = new Thread(new ThreadStart(processSecurity.Initialize));
DebugEngine\DebugControllerThread.cs (3)
18private Thread controllerThread = null; 58Thread.Sleep(10); 166Thread.Sleep(Timeout.Infinite);
DebugEngine\ProgramPublisher.cs (2)
49Thread publisherThread = new Thread(PublisherThreadFunc); 92Thread unpublisherThread = new Thread(UnpublishThreadFunc);
Hosting\DefaultWorkflowSchedulerService.cs (2)
69throw new ArgumentException(String.Format(Thread.CurrentThread.CurrentCulture, ExecutionStringManager.UnknownConfigurationParameter, "null")); 72throw new ArgumentException(String.Format(Thread.CurrentThread.CurrentCulture, ExecutionStringManager.UnknownConfigurationParameter, key));
Hosting\ManualWorkflowSchedulerService.cs (2)
87throw new ArgumentException(String.Format(Thread.CurrentThread.CurrentCulture, ExecutionStringManager.UnknownConfigurationParameter, "null")); 90throw new ArgumentException(String.Format(Thread.CurrentThread.CurrentCulture, ExecutionStringManager.UnknownConfigurationParameter, key));
Hosting\SqlWorkflowPersistenceService.cs (3)
470Exception e = new InvalidOperationException(string.Format(Thread.CurrentThread.CurrentCulture, ExecutionStringManager.InstanceNotFound, instanceStateId)); 527string.Format(Thread.CurrentThread.CurrentCulture, 792String.Format(Thread.CurrentThread.CurrentCulture, ExecutionStringManager.UnknownConfigurationParameter, key), "parameters");
WorkflowDefinitionDispenser.cs (2)
363Thread.MemoryBarrier(); 524Thread.MemoryBarrier();
WorkflowEventArgs.cs (1)
78Thread.MemoryBarrier();
WorkflowRuntime.cs (1)
607throw new InvalidOperationException(string.Format(Thread.CurrentThread.CurrentCulture, ExecutionStringManager.InstanceNotFound, instanceId));
System.Xml (5)
System\Xml\Schema\XmlSchemaSet.cs (1)
368Thread.Yield(); //Let the thread that holds the lock run
System\Xml\Serialization\XmlSerializationGeneratedCode.cs (2)
30threadCode = Thread.CurrentThread.GetHashCode(); 44if (tempAssembly != null && Thread.CurrentThread.GetHashCode() == threadCode)
System\Xml\XmlCharType.cs (1)
432Thread.MemoryBarrier(); // For weak memory models (IA64)
System\Xml\XPath\Internal\CompiledXPathExpr.cs (1)
134this.cinfo = System.Threading.Thread.CurrentThread.CurrentCulture;
System.Xml.Linq (2)
System\Xml\Linq\XLinq.cs (2)
613Thread.MemoryBarrier(); 791Thread.MemoryBarrier();
UIAutomationClient (3)
MS\Internal\Automation\HwndProxyElementProvider.cs (2)
496Thread.Sleep( 100 ); 1632System.Threading.Thread.Sleep(1);
MS\Internal\Automation\QueueProcessor.cs (1)
202Thread _thread; // the thread on which QueueItem's are processed
UIAutomationClientsideProviders (14)
MS\Internal\AutomationProxies\Misc.cs (2)
127System.Threading.Thread.Sleep(1); 989System.Threading.Thread.Sleep(50);
MS\Internal\AutomationProxies\QueueProcessor.cs (1)
68Thread thread = new Thread(threadStart);
MS\Internal\AutomationProxies\WindowsButton.cs (1)
529System.Threading.Thread.Sleep(1);
MS\Internal\AutomationProxies\WindowsListViewItem.cs (1)
809System.Threading.Thread.Sleep(1);
MS\Internal\AutomationProxies\WindowsMenu.cs (8)
1469System.Threading.Thread.Sleep(1); 1517System.Threading.Thread.Sleep(100); 1531System.Threading.Thread.Sleep(1); 1537System.Threading.Thread.Sleep(100); 2187System.Threading.Thread.Sleep(10); 2290System.Threading.Thread.Sleep(1); 2343System.Threading.Thread.Sleep(1); 2356System.Threading.Thread.Sleep(1);
MS\Internal\AutomationProxies\WindowsTreeView.cs (1)
639System.Threading.Thread.Sleep(1);
WindowsBase (25)
Base\MS\Internal\IO\Packaging\CustomSignedXml.cs (1)
272System.Threading.Thread.MemoryBarrier();
Base\MS\Internal\Verify.cs (1)
35if (Thread.CurrentThread.GetApartmentState() != requiredState)
Base\System\Windows\Interop\ComponentDispatcher.cs (3)
38_threadSlot = Thread.AllocateDataSlot(); 46object obj = Thread.GetData(_threadSlot); 50Thread.SetData(_threadSlot, data);
Base\System\Windows\Threading\Dispatcher.cs (9)
63Dispatcher currentDispatcher = FromThread(Thread.CurrentThread);; 84public static Dispatcher FromThread(Thread thread) 120Thread dispatcherThread = d.Thread; 188public Thread Thread 211return Thread == Thread.CurrentThread; 417Dispatcher currentDispatcher = FromThread(Thread.CurrentThread);; 1919_dispatcherThread = Thread.CurrentThread; 2429if (Thread.CurrentThread.GetApartmentState() == ApartmentState.STA) 3153private Thread _dispatcherThread;
Base\System\Windows\Threading\DispatcherOperation.cs (1)
214if(_dispatcher.Thread == Thread.CurrentThread)
Shared\MS\Internal\ReaderWriterLockSlimWrapper.cs (1)
275Dispatcher.FromThread(Thread.CurrentThread)?.DisableProcessing();
Shared\MS\Internal\TextServicesLoader.cs (1)
111Invariant.Assert(Thread.CurrentThread.GetApartmentState() == ApartmentState.STA, "Load called on MTA thread!");
Shared\MS\Win32\HandleCollector.cs (1)
137System.Threading.Thread.Sleep(sleep);
Shared\MS\Win32\HwndSubclass.cs (1)
373Dispatcher dispatcher = Dispatcher.FromThread(Thread.CurrentThread);
Shared\MS\Win32\HwndWrapper.cs (6)
69_ownerThreadID = new SecurityCriticalDataForSet<int>(Thread.CurrentThread.ManagedThreadId); 119if(null != Thread.CurrentThread.Name && 64 <= Thread.CurrentThread.Name.Length) 120threadName = Thread.CurrentThread.Name.Substring(0, 64); 122threadName = Thread.CurrentThread.Name; 245if(Thread.CurrentThread.ManagedThreadId == _ownerThreadID.Value)
WsatConfig (4)
CommandLine\ConsoleEntryPoint.cs (3)
256Thread.CurrentThread.CurrentUICulture = CultureInfo.CurrentUICulture.GetConsoleFallbackUICulture(); 259(System.Console.OutputEncoding.CodePage != Thread.CurrentThread.CurrentUICulture.TextInfo.OEMCodePage)) 261Thread.CurrentThread.CurrentUICulture = new CultureInfo("en-US");
Configuration\RemoteHelper.cs (1)
105System.Threading.Thread.Sleep(delayInAutoEventTimeout);
WsatUI (1)
Configuration\RemoteHelper.cs (1)
105System.Threading.Thread.Sleep(delayInAutoEventTimeout);