カスタムボタンとツールバーを表示するために作成したカスタムUIViewがあります。私が最初にそれを表示するよう呼びかけたとき、バーはシャッターの上にあります(それは良いです)。しかし、カメラがロードされた後、シャッターがその前に来て開きます。カメラシャッターがカスタムUIViewの前に表示されますか?
ネイティブcamera.appを見ると、これは行われません。ツールバーはその間ずっとそこにとどまっています。ここに私のコードは次のとおりです。
// .h
UIImagePickerController *theCamera;
@property (nonatomic, retain) UIImagePickerController *theCamera;
// .m
theCamera = [[UIImagePickerController alloc] init];
theCamera.delegate = self;
theCamera.sourceType = UIImagePickerControllerSourceTypeCamera;
theCamera.showsCameraControls = NO;
theCamera.toolbar.alpha = 0;
theCamera.navigationBarHidden = YES;
theCamera.toolbarHidden = YES;
theCamera.wantsFullScreenLayout = YES;
theCamera.cameraViewTransform = CGAffineTransformMakeScale(1.25, 1.25);
UIImageView *tabBarBack = [[UIImageView alloc] initWithImage:[UIImage imageNamed:@"tab_bar_back.png"]];
tabBarBack.frame = CGRectMake(0, 422, 320, 58);
[customView addSubview:tabBarBack];
theCamera.cameraOverlayView = customView;
[self presentModalViewController:theCamera animated:YES];
はもちろん、私はcustomView
に追加する多くのボタンがありますが、あなたはコンセプトを得ます。