(func, *args, **kwargs)
Call a function on the Main thread (async).
Call a function on the Main thread (async).
Call a function on the Main thread ( async ) .
def callAfter(func, *args, **kwargs):
    """
    Call a function on the Main thread (async).
    """
    pool = NSAutoreleasePool.alloc().init()
    runner = PyObjCMessageRunner.alloc().initWithPayload_((func, args, kwargs))
    runner.callAfter()
    del runner
    del pool
def callAfter ( func , * args , * * kwargs ) : pool = NSAutoreleasePool . alloc ( ) . init ( ) runner = PyObjCMessageRunner . alloc ( ) . initWithPayload_ ( ( func , args , kwargs ) ) runner . callAfter ( ) del runner del pool