简体   繁体   English

如何从UIImagePickerController的编辑屏幕中删除cameraOverlayView?

[英]How can I remove the cameraOverlayView from the editing screen of UIImagePickerController?

I've set a custom view as the cameraOverlayView of an UIImagePickerController 我已经将自定义视图设置为UIImagePickerControllercameraOverlayView
and enabled editing mode on it. 并启用了编辑模式。

Now when it switches to editing mode the overlay view is still there. 现在,当它切换到编辑模式时,覆盖视图仍然存在。 How can I remove it from the editing view? 如何将其从编辑视图中删除?

I haven't found anything related to this in the official documentation. 我没有在官方文档中找到与此相关的任何内容。

Have you tried view.removeFromSuperview ? 您是否尝试过view.removeFromSuperview

I take it you've implemented the delegate function 我认为您已经实现了委托功能

optional func imagePickerController(_ picker: UIImagePickerController,
  didFinishPickingMediaWithInfo info: [String : AnyObject])

and this happens before that function gets called. 而这发生在该函数被调用之前。

Can your custom view detect that its parent has changed and remove itself? 您的自定义视图可以检测到其父视图已更改并删除吗?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 UIImagePickerController cameraOverlayView无法在iPad上全屏显示 - UIImagePickerController cameraOverlayView can not be full screen on the iPad 带有cameraOverlayView的UIImagePickerController-放错视图 - UIImagePickerController with cameraOverlayView - misplaced views 将cameraOverlayView与UIImagePickerController一起使用 - Using cameraOverlayView with UIImagePickerController cameraOverlayView在UIImagePickerController中裁剪结果 - cameraOverlayView to crop the result in UIImagePickerController UIImagePickerController cameraOverlayView无法在iPhone 5上使用? - UIImagePickerController cameraOverlayView not working with iPhone 5? UIImagePickerController的cameraOverlayView立即消失 - cameraOverlayView of UIImagePickerController disappears immediately UIImagePickerController cameraOverlayView中的透明度 - transparency in UIImagePickerController cameraOverlayView 如何在模拟器环境中使用 UIImagePickerController 的 CameraOverlayView 属性 - How to use UIImagePickerController 's CameraOverlayView property in Simulator environment 如何判断UIImagePickerController cameraOverlayview是否旋转? - How do you tell whether UIImagePickerController cameraOverlayview will rotate or not? cameraOverlayView阻止使用allowsEditing进行编辑 - cameraOverlayView prevents editing with allowsEditing
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM