0

我面临一个我不明白的问题。

在我的主视图中,我有一个指向另一个视图的按钮。一切都嵌入在 NavigationController 中。

我在主视图中成功更改了 NavigationBar 的背景图像。但是,当我单击按钮以显示我的其他视图时,我的 NavigationBar 没有重新绘制,尽管我正在使用此代码:

- (IBAction) toOtherView : (id) sender
{
    if(!otherView) otherView = [[OtherViewController alloc] initWithNibName:@"OtherViewController" bundle:nil];
    [self.navigationController pushViewController:otherView animated:NO];
}

但是,我的主视图上还有一个 Dark Info 按钮(我一开始选择了默认的 Utility Application)。它翻转到另一个视图,当我回到主视图时,导航栏图像已更改。所以我猜这是重绘的问题。但我能在这里做什么?

非常感谢您的建议。

4

0 回答 0