Closed andre-vm closed 1 year ago
if "pictureFile" is null,"pictureFile?.absolutePath" will not run in Kotlin. so, the code not executed.
@XingSpace The second snippet works fine. The problem here is about the behavior of imageViewPicture.setImageURI(pictureFile?.toUri())
. When pictureFile
is null, that call is equivalent to imageViewPicture.setImageURI(null)
, which should clear the image view, but it doesn't.
Hi! Thank you for such a nice library! I just replaced an ImageView with a RoundedImageView (2.3.0), and I have this call inside my fragment:
When
pictureFile
is null, the previous image remains visible, unexpectedly. In order to solve the problem, I changed the code to this: