FirstViewController.m
UIViewController *vc = [SecondViewController init];
vc.view.backgroundColor = [UIColor clearColor];
self.modalPresentationStyle = UIModalPresentationCurrentContext;/*设置这个属性背景就是透明的,而不是黑色的了*/
[self presentModalViewController:vc animated:NO];
版权声明:本文为博主原创文章,未经博主允许不得转载。