Attempt to fix #1961

Namely this commit changes two things:
1) In the past the user manager window technically was closed after it was released (SPUserManager.m:491):

    [NSApp endSheet:[self window] returnCode:0]; //-> calls delegate,  which calls release
    [[self window] orderOut:self];

This call order has now been swapped.
2) Because the delegate is invoked directly by NSApp, the release was called before other UI elements had finished their cleanup from orderOut:. The delegate callback is now put on the runloop to give other stuff priority.

Requesting QA on this commit.