Issue
Warning says: This folder configuration ('v24') is unnecessary; 'minSdkVersion' is 24. Merge all the resources in this folder into 'drawable-anydpi'.
And when I rename drawable-anydpi-v24 to drawable-anydpi then, it says resource collide with another resource file (png collides with xml). That is there exists a same resource file with .xml extension.
Please note that in drawable-anydpi-v24 there is png notification icon file.
And also there is not any folder with name drawable-anydpi. So I renamed drawable-anydpi-v24 to drawable-anydpi.
My current project has this drawable folders: drawable, drawable-anydpi-v24, drawable-hdpi, drawable-mdpi, drawable-nodpi, drawable-v24, drawable-xhdpi, drawable-xxhdpi, drawable-xxxhdpi
So, in my case, how to get rid of this warning?
Solution
Move your notification icons from drawable-anydpi-v24
to drawable
don't create drawable-anydpi
for this because anydpi takes precedence over other qualifiers and that might be causing you the issue of png collides with xml
.
And if you already have an XML version of your asset (ic_notification_icon as a vector asset) in drawable then you don't even have to move your png because now vector asset can work in all of the condition because you moved to higher minSDK.
Answered By - Dinkar Kumar
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.