Closed henryqwe closed 5 years ago
Shimmer just masks content underneath it. If you want it to mask something with rounded corners then just create that something and put it in a ShimmerFrameLayout
. You can see this in the sample app.
@xiphirx I want to use ShimmerDrawable
as placeholder in Glide and it only accepts Drawable
object
Still, create a Drawable
that draws your rounded rect and wrap it with ShimmerDrawable
.
@xiphirx Could you provide some example because i don't get what you mean by saying wrap Drawable
with ShimmerDrawable
I need help for this issue also. I tried to use ShimmerDrawable
as glide placeholder, in my rounded corner cardview, it shows black colored solid corner, but after the image is loaded, then its okay.
If i use the xml approach which wrap the imageview inside a ShimmerFrameLayout, then no black colored corner is shown.
I also tried the suggested way by @xiphirx to wrap the shimmerdrawable using DrawableCompat.wrap
, I get a drawable object. How do i convert this to GradiantDrawable
for me to set its corner radius?
Please help. Thanks :)
@xiphirx up
Have you find the way of doing it?
any update?
Do we have any solution?
I need help for this issue also. I tried to use
ShimmerDrawable
as glide placeholder, in my rounded corner cardview, it shows black colored solid corner, but after the image is loaded, then its okay. If i use the xml approach which wrap the imageview inside a ShimmerFrameLayout, then no black colored corner is shown.I also tried the suggested way by @xiphirx to wrap the shimmerdrawable using
DrawableCompat.wrap
, I get a drawable object. How do i convert this toGradiantDrawable
for me to set its corner radius? Please help. Thanks :)Do we have any solution?
any update?
Have you find the way of doing it?
using cardview gives you rounded corners, I tried many ways to eliminate black colored solid corners the only simple working way was giving a small padding to imageview like 1dp 2dp and that's it. that 1dp or 2dp white padding is not noticeable at least it's better than black corners.
It would be great to add ShimmerDrawable with rounded corner. Is there a plan for implementing such feature?