UPDATE
根据Tim的回答,我在每个视图控制器中实现了以下内容,该控制器具有作为自定义容器一部分的scrollview(或子类):
- (void)didMoveToParentViewController:(UIViewController *)parent
{
if (parent) {
CGFloat top = parent.topLayoutGuide.length;
CGFloat bottom = parent.bottomLayoutGuide.length;
// this is the most important part here, because the first view controller added
// never had the layout issue, it was always the second. if we applied these
// edge insets to the first view controller, then it would lay out incorrectly.
// first detect if it's laid out correctly with the following condition, and if
// not, manually make the adjustments …Run Code Online (Sandbox Code Playgroud) 我正在将我的项目转移到iOS7.我正面临着与半透明导航栏相关的奇怪问题.
我有一个视图控制器,它有一个tableview作为子视图(让我们称之为ControllerA).我使用controllerA初始化一个新的uinavigationcontroller并使用presentviewcontroller以模态方式呈现它.导航栏会阻止显示的视图控制器的表视图.我将automaticAdjustsScrollViewInsets设置为YES,但结果没有改变.我知道我可以将edgesForExtendedLayout设置为UIRectEdgeNone,但它会使导航栏不再是半透明的.
之后,我尝试创建一个新的视图控制器进行测试.它包含几乎相同的元素.但结果却大相径庭.表视图内容不会被阻止.

结论