Skip to content

When clearing the image using .setImageBitmap(null) a nullpointer exception occurs #59

@timkoers

Description

@timkoers

When clearing the current image using setImageBitmap(null) a nullpointer exception occurs:

java.lang.NullPointerException:
Attempt to invoke virtual method 'int android.graphics.Bitmap.getWidth()' on a null object reference
at android.graphics.Bitmap.createScaledBitmap(Bitmap.java:591)
at com.pkmmte.view.CircularImageView.refreshBitmapShader(CircularImageView.java:341)
at com.pkmmte.view.CircularImageView.invalidate(CircularImageView.java:262)
at android.widget.ImageView.setImageDrawable(ImageView.java:456)
at android.widget.ImageView.setImageBitmap(ImageView.java:548)

This should not happen, the default ImageView doesn't do this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions