将UIImagePickerController添加为子视图时,快门动画搞砸了

时间:2012-11-26 10:44:56

标签: ios uinavigationcontroller uiimagepickercontroller uipopovercontroller

我正在添加UIImagePickerController作为UINavigationControllerUIPopoverController的子视图。

下面是代码:

        UIViewController *container = [[UIViewController alloc] init];
        self.navigationBarHidden = YES;

        camera = [[UIImagePickerController alloc] init];
        camera.sourceType = UIImagePickerControllerSourceTypeCamera;

        [container addChildViewController:camera];
        [container.view setFrame:camera.view.frame];
        [container.view addSubview:camera.view];

        [self pushViewController:container animated:YES];

一切看起来都不错,但快门动画。它似乎偏离中心,虹膜的中间实际上是在视线的顶部。

如何修复快门动画?

0 个答案:

没有答案