当您现在选择"UIModalPresentationFormSheet“时,是否可能有视图的自定义大小,这似乎超出了我们的控制范围?
根据下面的链接,您似乎无法更改默认大小。
http://www.thizzer.com/2011/05/uimodalpresentationstyle-frame-size-ipad/
发布于 2011-06-14 12:51:59
MyModalViewController *targetController = [[[MyModalViewController alloc] init] autorelease];
targetController.modalPresentationStyle = UIModalPresentationFormSheet;
targetController.modalTransitionStyle = UIModalTransitionStyleFlipHorizontal; //transition shouldn't matter
[self presentModalViewController:targetController animated:YES];
targetController.view.superview.frame = CGRectMake(0, 0, 200, 200);//it's important to do this after
targetController.view.superview.center = self.view.center;https://stackoverflow.com/questions/6343587
复制相似问题