{"action":"created","issue":{"url":"https://api.github.com/repos/vinc3m1/RoundedImageView/issues/121","labels_url":"https://api.github.com/repos/vinc3m1/RoundedImageView/issues/121/labels{/name}","comments_url":"https://api.github.com/repos/vinc3m1/RoundedImageView/issues/121/comments","events_url":"https://api.github.com/repos/vinc3m1/RoundedImageView/issues/121/events","html_url":"https://github.com/vinc3m1/RoundedImageView/issues/121","id":105070443,"number":121,"title":"Ion + RIV(oval=true) is not ovaled always","user":{"login":"b1rdex","id":312855,"avatar_url":"https://avatars.githubusercontent.com/u/312855?v=3","gravatar_id":"","url":"https://api.github.com/users/b1rdex","html_url":"https://github.com/b1rdex","followers_url":"https://api.github.com/users/b1rdex/followers","following_url":"https://api.github.com/users/b1rdex/following{/other_user}","gists_url":"https://api.github.com/users/b1rdex/gists{/gist_id}","starred_url":"https://api.github.com/users/b1rdex/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/b1rdex/subscriptions","organizations_url":"https://api.github.com/users/b1rdex/orgs","repos_url":"https://api.github.com/users/b1rdex/repos","events_url":"https://api.github.com/users/b1rdex/events{/privacy}","received_events_url":"https://api.github.com/users/b1rdex/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":7,"created_at":"2015-09-06T04:30:30Z","updated_at":"2015-11-24T07:35:29Z","closed_at":null,"body":"My app has contact list. ListView avatar + name. Avatars are defined with remote HTTP URIs.\r\nAvatars are loaded with Ion. Avatar has default value set.\r\nIon requests set to placeholder and error values with default avatar.\r\nSo we must get user avatar or default one.\r\n\r\nAnd here is the problem: errored avatar is not always ovaled. Scrolling ListView to redraw items makes them oval.\r\n\r\nThis are errors:\r\n\r\nlook at 10008 & 10009 | look at 10011\r\n------------ | -------------\r\n![screenshot_2015-09-06-14-18-28](https://cloud.githubusercontent.com/assets/312855/9702478/7aad7b7e-54a2-11e5-969d-e14d77293271.png) | ![screenshot_2015-09-06-14-18-33](https://cloud.githubusercontent.com/assets/312855/9702479/7aae210a-54a2-11e5-8cb6-306e4f03beff.png)\r\n\r\nThese are redrawen good after scroll:\r\n\r\nlook at 10008 & 10009 | look at 10011\r\n------------ | -------------\r\n![screenshot_2015-09-06-14-18-36](https://cloud.githubusercontent.com/assets/312855/9702494/3df33d8a-54a3-11e5-9e2d-a3e370bc2466.png) | ![screenshot_2015-09-06-14-18-40](https://cloud.githubusercontent.com/assets/312855/9702495/3df3ad92-54a3-11e5-8e30-e650e3652e00.png)\r\n\r\nThis is my XML:\r\n```XML\r\n<com.makeramen.roundedimageview.RoundedImageView\r\n        android:id=\"@+id/I_avatar\"\r\n        android:layout_width=\"@dimen/big_avatar_width\"\r\n        android:layout_height=\"@dimen/big_avatar_height\"\r\n        android:adjustViewBounds=\"true\"\r\n        android:contentDescription=\"User avatar\"\r\n        android:scaleType=\"centerCrop\"\r\n        android:src=\"@drawable/default_avatar\"\r\n        app:riv_oval=\"true\" />\r\n```\r\n\r\nThis method is called from contacts adapter `getView`:\r\n```java\r\npublic static void setAvatarWithIon(final ImageView avatarView, final String avatarUri) {\r\n    final int defaultAvatar = R.drawable.default_avatar;\r\n\r\n    if (avatarUri != null && !avatarUri.isEmpty()) {\r\n        Ion.with(avatarView)\r\n                .placeholder(defaultAvatar)\r\n                .error(defaultAvatar)\r\n                .load(avatar)\r\n        ;\r\n    } else {\r\n        avatarView.setImageResource(defaultAvatar);\r\n    }\r\n}\r\n```"},"comment":{"url":"https://api.github.com/repos/vinc3m1/RoundedImageView/issues/comments/159183485","html_url":"https://github.com/vinc3m1/RoundedImageView/issues/121#issuecomment-159183485","issue_url":"https://api.github.com/repos/vinc3m1/RoundedImageView/issues/121","id":159183485,"user":{"login":"b1rdex","id":312855,"avatar_url":"https://avatars.githubusercontent.com/u/312855?v=3","gravatar_id":"","url":"https://api.github.com/users/b1rdex","html_url":"https://github.com/b1rdex","followers_url":"https://api.github.com/users/b1rdex/followers","following_url":"https://api.github.com/users/b1rdex/following{/other_user}","gists_url":"https://api.github.com/users/b1rdex/gists{/gist_id}","starred_url":"https://api.github.com/users/b1rdex/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/b1rdex/subscriptions","organizations_url":"https://api.github.com/users/b1rdex/orgs","repos_url":"https://api.github.com/users/b1rdex/repos","events_url":"https://api.github.com/users/b1rdex/events{/privacy}","received_events_url":"https://api.github.com/users/b1rdex/received_events","type":"User","site_admin":false},"created_at":"2015-11-24T07:35:29Z","updated_at":"2015-11-24T07:35:29Z","body":"Ilya, that's what I'm talking about — RIV is not detecting image update so\nnot applying oval transformation. But RIV creator just says \"that's not\ntrue and impossible\". :-)\n\n2015-11-24 17:33 GMT+10:00 ilyamuromets <notifications@github.com>:\n\n> I found a solution.\n> After image downloading complete I make it oval with:\n>\n> RoundedDrawable roundedDrawable = RoundedDrawable.fromBitmap(bitmap).setOval(true);\n>\n> ... and then I put oval image into TransitionDrawable.\n>\n> —\n> Reply to this email directly or view it on GitHub\n> <https://github.com/vinc3m1/RoundedImageView/issues/121#issuecomment-159182937>\n> .\n>\n"}}