I am newbie in objective-c.I want to pause the execution of main thread until my application keyWindow has been closed.I have tried by following code
[mywindow performSelector:@selector(isVisible:) onThread:[NSThread currentThread] withObject:self waitUntilDone:YES];
It's hold the execution.After close mywindow main thread doesn't execute(Paused in same line).How can I do it?