2013-12-16 79 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這個問題的答案可能會幫助你 –