在我的应用程序中,我希望有一个图像来覆盖主视图控制器和细节视图控制器的导航栏。我尝试通过设置 UISplitviewController navigationItem.title 视图在 AppDelgate 中执行此操作,但它不起作用。
有什么建议么 ??
这是 AppDelegate didFinishLaunching 方法中的代码
UISplitViewController *splitViewController = (UISplitViewController *)self.window.rootViewController;
UINavigationController *navigationController = [splitViewController.viewControllers lastObject];
splitViewController.delegate = (id)navigationController.topViewController;
UINavigationController *masterNavigationController = splitViewController.viewControllers[0];
BAMasterViewController *controller = (BAMasterViewController *)masterNavigationController.topViewController;
controller.managedObjectContext = self.managedObjectContext;
return YES;