我在appdelegate中添加了一个视图。我已将此视图添加到不同的控制器中
if((orientation == UIInterfaceOrientationLandscapeLeft)||(orientation ==
UIInterfaceOrientationLandscapeRight))
{
[topview setFrame:CGRectMake(0, 0, 1024, topview.frame.size.height)];
}
else if ((orientation == UIInterfaceOrientationPortrait)||(orientation ==
UIInterfaceOrientationPortraitUpsideDown))
{
[topview setFrame:CGRectMake(0, 0, 768, topview.frame.size.height)];
}
[self.view addSubview:topview];
此topView包含按钮。但它不能用于UIInterfaceOrientationPortraitUpsideDown,虽然按钮在正确的位置可见。
有没有解决方案?