DKImagePickerController icon indicating copy to clipboard operation
DKImagePickerController copied to clipboard

Camera Thumbnail will not show up if no images on device

Open pathaderavi-zz opened this issue 7 years ago • 6 comments

img_0005 Camera thumbnail does not show up in the gallery if there are no images on the current device (Only for Photos mode).

pathaderavi-zz avatar Jan 23 '19 19:01 pathaderavi-zz

Hi @pathaderavi It's a little odd, there are no Camera Roll and Favorites albums on your device?

From iPad Air Simulator: simulator screen shot - ipad air 2 - 2019-02-26 at 21 25 47

zhangao0086 avatar Feb 26 '19 13:02 zhangao0086

I am facing the same issue. Camera image is not loaded. Shows up on first time but later no image in the cell.

    public class func imageForResource(_ name: String, stretchable: Bool = false, cacheable: Bool = false) -> UIImage {

...

        let bundle = Bundle.imagePickerControllerBundle()
...
}

Printing description of bundle: NSBundle </Users/app-path/appname.app/Frameworks/DKImagePickerController.framework/DKImagePickerController.bundle> (not yet loaded)

Please see the attached screenshot.

simulator screen shot - iphone xs max - 2019-03-03 at 19 01 47

Rahulrvarma22 avatar Mar 03 '19 13:03 Rahulrvarma22

Hi @pathaderavi It's a little odd, there are no Camera Roll and Favorites albums on your device?

From iPad Air Simulator: simulator screen shot - ipad air 2 - 2019-02-26 at 21 25 47

The issue is not with Camera Roll or Favorite tile, but the "Camera" tile which opens the camera.

pathaderavi-zz avatar Mar 07 '19 18:03 pathaderavi-zz

@pathaderavi I know the issue is not with Camera Roll or Favorite. This issue means that there are no any albums on the device, and the Camera tile needs to be displayed in an album.

Maybe the logic of the Camera tile display should not be associated with the albums: https://github.com/zhangao0086/DKImagePickerController/commit/ec0e70e8908955edbb2be55e8f3a68b1c5863f8b

zhangao0086 avatar Mar 08 '19 08:03 zhangao0086

Hi @zhangao0086 will this solve my problem (https://github.com/zhangao0086/DKImagePickerController/issues/576#issuecomment-469023359) also of the camera image not showing up on the 1st tile?

Rahulrvarma22 avatar Mar 13 '19 03:03 Rahulrvarma22

@Rahulrvarma22 No. It's a different issue. Please try to clean your project with Shift-Alt-Cmd-K and delete the derived data.

zhangao0086 avatar Mar 13 '19 03:03 zhangao0086