How can I load non-resource Drawable?
See original GitHub issueDescription
Such as GradientDrawable
, ColorDrawable
, It is not a URI, I use drawee.setImageDrawable
but can’t work like ImageView.
Additional Information
- Fresco version: 1.13.0
- Platform version: Android 7.0
Issue Analytics
- State:
- Created 4 years ago
- Comments:6 (2 by maintainers)
Top Results From Across the Web
How to access drawable from non activity class - Stack Overflow
Pass the context object as a parameter to the constructor of the non Activity class. Then use that context object to get the...
Read more >Drawable resources - Android Developers
A drawable resource is a general concept for a graphic that can be drawn to the screen and which you can retrieve with...
Read more >How To Add an Image to the Drawable Folder| Android Studio ...
Android Resources Part 1: How To Add an Image to the Drawable Folder| Android Studio Tutorial · Key moments. View all · Key...
Read more >Can't load resource drawable Uri if drawable is a vector #2137
Loading an Uri pointing to a resource drawable "android.resource://package/drawable/ic_facebook" fails if the drawable is a Vector.
Read more >image files in Resources drawable do not appear in Xamrin ...
If you meet error: 'Resource.Drawable' does not contain a definition for 'icon1' and you have added the image to Resources/drawable folder.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
You can set a drawable as placeholder. If you think you need to, you can also set it like this:
I found a solution in ColorImageExample