2013-12-16 35 views
0

我有酥料饼,这是从代码呈现状态栏隐藏:如何防止酥料饼从iOS6的

CGPoint screenPoint = [self.mapView screenPoint: self.selectedObject.pointCoordinate]; 
    CGRect rect = CGRectMake(screenPoint.x, screenPoint.y, 1, 1); 
    [self.detailViewPopover presentPopoverFromRect:rect inView:self.view permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES]; 

为u可以在截图中看到 - 在酥料饼是由状态栏隐藏 - 是否可以将弹出窗口应该显示的区域排除状态栏框?

内容大小鉴于酥料饼看起来是这样的:

self.contentSizeForViewInPopover = CGSizeMake (320, self.view.frame.size.height - 100); 

enter image description here

回答

3

您的UIPopoverArrowDirectionUp重置UIPopoverArrowDirectionAny

[self.listViewPopover presentPopoverFromRect:rect inView:self.view permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES]; 
+0

哦,对不起,请参阅编辑的问题 - 有是我的错 - 我发布了错误的代码来展示popover。这就是它现在的样子.. – ShurupuS

+1

http://stackoverflow.com/questions/11757690/position-of-uipopovercontroller-in-ipad这个问题的答案可能会帮助你 –