move window alloc to applicationDidFinishLaunch