iOS Guides | Samples

MonoTouch.UIKit.UIApplication.CheckForIllegalCrossThreadCalls Field

Determines whether the debug builds of MonoTouch will enforce that calls done to UIKit are only issued from the UI thread.


public static Boolean CheckForIllegalCrossThreadCalls


On debug builds, MonoTouch will enforce that calls made to UIKit APIs are only done from the UIKit thread. This is useful to spot code that could inadvertently use UIKit from a non-UI thread which can corrupt the UIKit state and could lead to very hard to debug problems.

But sometimes it might be useful to disable this check, either because you can ensure that UIKit is not in use at this point or because MonoTouch might be enforcing the checks in APIs that might have later been relaxed or made thread safe by iOS.


Namespace: MonoTouch.UIKit
Assembly: monotouch (in monotouch.dll)
Assembly Versions: