執行從Default.png
到初始應用程序視圖的逐漸(0.5秒)淡出的最簡單/最快/最有效的方式是什麼?從iPhone默認位圖淡入主應用程序
我最初的嘗試,它不工作這麼好..它是星期六晚上,讓我們看看我們是否能夠比使用setAnimationDelay:
代替setAnimationDuration:
做的更好:)
UIImageView* whiteoutView = [[UIImageView alloc] initWithFrame:self.view.frame]; // dealloc this later ??
whiteoutView.image = [UIImage imageNamed:@"Default.png"];
whiteoutView.alpha = 1.0;
[self.view.frame addSubview:whiteoutView];
[UIView beginAnimations:nil context:nil];
[UIView setAnimationDelay:0.5];
whiteoutView.alpha = 0;
[UIView commitAnimations];
作品,除了在我的情況下,我有一個UITabBarController,必須做'[self tabBarController] .view'而不是'self.view'。作品! – sehugg 2010-01-24 05:46:19