CircleImageView 3.0.1 released

Yesterday I published a bugfix release of CircleImageView with two small fixes for the improved touch handling introduced earlier this year. The new version 3.0.1 is now available on Maven Central.

With CircleImageView 3.0.0 I tweaked the touch handling to align the touchable area with what is actually drawn. Before this change a touch event outside of the visible circle but inside that virtual square enclosing it would fire an  onClick callback, which was quite unexpected. This has been changed since, but unfortunately I missed two edge-cases in the implementation.

The first case was triggered if the view was empty, i.e. no image has been set. In this case no onClick callback was fired at all in case of a touch event, which was different from the behavior of a regular ImageView, which fires the callback even if the view is empty. The behavior has now been aligned so a touch event on an empty CircleImageView also triggers a callback.

The second case is even more edgy: within CircleImageView there's an option to temporarily disable the circular transformation of the source bitmap. This option was ignored when determining if a touch event needs to be handled, resulting in only a circular area being touchable while a full square image was visible. This has been fixed so the touchable area aligns with what's visible.

Head over to GitHub for the full diff and update your dependencies to point to the new version:

dependencies {
    ...
    implementation 'de.hdodenhof:circleimageview:3.0.1'
}

Happy coding!