0

当我们从导航栏返回视图控制器时,有什么方法可以释放吗?

当我从导航栏返回屏幕时,我想重新加载 NIB。

可能吗?

谢谢

4

1 回答 1

2

您可能viewWillAppear:animated想看看viewDidAppear:animated. UIViewController每次将视图控制器推送到显示时都会调用它们。

- (void)viewWillAppear:(BOOL)animated {

    [super viewWillAppear:animated];
    // Reload your data here, and this gets called
    // before the view transition is complete.
}

- (void)viewDidAppear:(BOOL)animated {

    [super viewDidAppear:animated];
    // Reload your data here, and this gets called
    // after the view transition is complete.
}
于 2012-10-18T12:33:47.263 回答