私は5つのタブを含むタブバーを持っています。私のアプリケーションでは、ユーザーはログインする必要はありません。ユーザーがサインアップまたはログインすると、一部の機能のみが許可されます。Skip Login NavControllerのコントローラを表示
ユーザがすでに登録/ログインしている場合、NavigationController
に接続されているUserViewController
に次のロジックを実装しました。しかし、次のロジックでは、ユーザーは1秒〜2秒でViewControllerを見ることができました。
-(void) viewWillAppear: (BOOL) animated
{
if(isRegistered)
{
UIStoryboard *storyboard = [UIStoryboard storyboardWithName:@"Main" bundle:nil];
UserProfileViewController *vc = [storyboard instantiateViewControllerWithIdentifier:@"UserProfileVewController"];
[self.navigationController pushViewController:vc animated:YES];
}
}
ユーザーが既に登録されているかどうか、UserViewControllerをスキップできますか? UserProfileVewController
に直接アクセスするには、UserViewController
ではなく、login/signup viewcontrollerです。プロジェクトのAppDelegateで