25 references to GetApartmentState
Microsoft.Build (4)
BackEnd\Components\RequestBuilder\RequestBuilder.cs (1)
729
if (Thread.CurrentThread.
GetApartmentState
() == ApartmentState.STA)
BackEnd\Components\RequestBuilder\TaskBuilder.cs (1)
438
&& (Thread.CurrentThread.
GetApartmentState
() != ApartmentState.STA)
Instance\RunningObjectTable.cs (2)
31
if (Thread.CurrentThread.
GetApartmentState
() == ApartmentState.MTA)
60
if (Thread.CurrentThread.
GetApartmentState
() == ApartmentState.MTA)
Microsoft.VisualBasic.Forms (1)
Microsoft\VisualBasic\Interaction.vb (1)
221
If Thread.CurrentThread.
GetApartmentState
() <> ApartmentState.STA Then
PresentationCore (14)
System\Windows\Input\InputManager.cs (1)
143
if(Thread.CurrentThread.
GetApartmentState
() != ApartmentState.STA)
System\Windows\Input\InputProcessorProfiles.cs (1)
63
Debug.Assert(Thread.CurrentThread.
GetApartmentState
() == ApartmentState.STA, "Initialize called on MTA thread!");
System\Windows\Input\InputProcessorProfilesLoader.cs (1)
60
Debug.Assert(Thread.CurrentThread.
GetApartmentState
() == ApartmentState.STA, "Load called on MTA thread!");
System\Windows\Input\TextServicesContext.cs (1)
47
Debug.Assert(Thread.CurrentThread.
GetApartmentState
() == ApartmentState.STA, "SetDispatcherThreaad on MTA thread");
System\Windows\Media\Effects\BitmapEffect.cs (1)
27
if (Thread.CurrentThread.
GetApartmentState
() != ApartmentState.STA)
System\Windows\OleServicesContext.cs (9)
105
if (Thread.CurrentThread.
GetApartmentState
() != ApartmentState.STA)
118
if (Thread.CurrentThread.
GetApartmentState
() != ApartmentState.STA)
131
if (Thread.CurrentThread.
GetApartmentState
() != ApartmentState.STA)
147
if (Thread.CurrentThread.
GetApartmentState
() != ApartmentState.STA)
161
if (Thread.CurrentThread.
GetApartmentState
() != ApartmentState.STA)
189
if (Thread.CurrentThread.
GetApartmentState
() != ApartmentState.STA)
202
if (Thread.CurrentThread.
GetApartmentState
() != ApartmentState.STA)
228
if (Thread.CurrentThread.
GetApartmentState
() != ApartmentState.STA)
258
if (Thread.CurrentThread.
GetApartmentState
() != ApartmentState.STA)
PresentationFramework (3)
System\Windows\Documents\TextServicesHost.cs (1)
62
Debug.Assert(Thread.CurrentThread.
GetApartmentState
() == ApartmentState.STA, "OnRegisterTextStore must be called on STA thread");
System\Windows\Standard\Debug.cs (1)
339
if (Thread.CurrentThread.
GetApartmentState
() != expectedState)
System\Windows\Standard\Verify.cs (1)
41
if (Thread.CurrentThread.
GetApartmentState
() != requiredState)
System.Collections.Concurrent (1)
System\Collections\Concurrent\BlockingCollection.cs (1)
1663
((collections.Length == 63) && (Thread.CurrentThread.
GetApartmentState
() == ApartmentState.STA)))
System.Private.CoreLib (1)
src\libraries\System.Private.CoreLib\src\System\Threading\Thread.cs (1)
506
get =>
GetApartmentState
();
System.Windows.Forms.UI.IntegrationTests (1)
Infra\ControlTestBase.cs (1)
71
if (Thread.CurrentThread.
GetApartmentState
() == ApartmentState.STA)