diff --git a/LGHelper/LGHelper.m b/LGHelper/LGHelper.m index 47f0255..c62c19a 100644 --- a/LGHelper/LGHelper.m +++ b/LGHelper/LGHelper.m @@ -2648,6 +2648,13 @@ - (BOOL)imagePickerControllerShowWithSourceType:(UIImagePickerControllerSourceTy _imagePickerController.delegate = (delegate ? delegate : self); if (setupHandler) setupHandler(_imagePickerController); + + //必须加上这一句,否则可能会导致在关闭弹出窗口的时候状态栏出现黑色(原因可能是修改了全局导航栏背景色) + if ([[[UIDevice currentDevice] systemVersion] floatValue]>=8.0) { + _imagePickerController.modalPresentationStyle=UIModalPresentationOverCurrentContext; + }else{ + _imagePickerController.modalPresentationStyle=UIModalPresentationCurrentContext; + } [viewController presentViewController:_imagePickerController animated:animated completion:presentCompletionHandler]; }