Checks UIView methods are being called on the correct thread. Swift re-work of PSPDFUIKitMainThreadGuard.m.
Drag into project. Add a preprocessor macro in build settings for the debug build: DEBUG=1
and in Other Swift Flags: -DDEBUG
. Add the following to the top of your App Delegate:
override init() {
super.init()
UIView.classInit
}
MIT