lijunda
2018-08-16 64b0493e4bd40c46e341fd5de9f1862998c431b0
pregnancy_guard/BaseProject/AppDelegate.m
@@ -81,6 +81,7 @@
    LoginPage *root = [[LoginPage alloc]init];
    UINavigationController *nav = [[UINavigationController alloc]initWithRootViewController:root];//先将root添加在navigation上
    nav.navigationBarHidden = YES;
    NSLog(@"123");
    [self.window setRootViewController:nav];//navigation加在window上
    [self.window makeKeyAndVisible];
}
@@ -110,22 +111,9 @@
    [self.internetReachability startNotifier];
    [self updateInterfaceWithReachability:self.internetReachability];
    
    // Override point for customization after application launch.
    UIUserNotificationType types = UIUserNotificationTypeBadge |
    UIUserNotificationTypeSound | UIUserNotificationTypeAlert;
    
    UIUserNotificationSettings *mySettings =
    [UIUserNotificationSettings settingsForTypes:types categories:nil];
    
    if(mySettings != nil)
    {
        [[UIApplication sharedApplication] registerUserNotificationSettings:mySettings];
    }
    //_currentDevice = _selectedDevice.mac;
    [self showHomePage];
    [self showLoginPage];
    
    //异常对象:NSException
    //参数:将函数的地址给它