[英]Custom “Use”, “Cancel”,“Retake” and “Reverse Camera” button event using UIImagePickerController
I am making a custom photo picker. 我正在制作自定义照片选择器。 so i have used
所以我用过
imagePickerController.showsCameraControls = NO;
And i have created one camera overlay view and use 我创建了一个相机叠加视图并使用
imagePickerController.cameraOverlayView = overlayView;
So, I need to implement custom button option, Can anyone please tell me how can i give customize button event using UIImagePickerController? 因此,我需要实现自定义按钮选项,有人可以告诉我如何使用UIImagePickerController给出自定义按钮事件吗?
Thanks in advance. 提前致谢。
You can build a UIViewController, take it's view as the image picker's overlayView. 您可以构建一个UIViewController,将其视图作为图像选择器的overlayView。 All your custom buttons are controlled by this UIViewController.
您所有的自定义按钮都由此UIViewController控制。
eg 例如
UIButton *myBtn = [[UIButton alloc] initWithFrame:btnFrame];
[myBtn addTarget:self action:@selector(myBtnPressed) forControlEvents:UIControlEventTouchUpInside];
[overlayView addSubview:myBtn];
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.