在我的AppDelegate.h我有@property (nonatomic, strong) IBOutlet UIWindow *window和@property (nonatomic, strong) IBOutlet UITabBarController *tabBarController。
在实施 I @synthesize *window = _window, *tabBarController = _tabBarController;.
在我的目标设置中,MainWindow.xib指定了我的文件。
在我的MainWindow.xib文件中,我有三个对象:AppDelegate、Window和Tab Bar Controller. 我连接Window到AppDelegate、和。Tab Bar Controller_Window.rootViewControllerTab Bar ControllerAppDelegate
回到 中AppDelegate.h,出口圆圈显示为已连接。
最后,在我的AppDelegate.m文件中:
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
[self.window makeKeyAndVisible];
NSLog(@"%@",self.window);
return YES;
}
此日志的内容始终为(null).
在应用程序启动时,窗口和标签栏控制器出现并接收用户交互。
出了什么问题?