Reputation: 2492
I understand that those new attributes are safely ignored in older APIs. Now is there any way to make this following Lint warning go away without suppressing it or raising the minSdk?
Attribute shortcutId is only used in API level 25 and higher (current min is 15) less... (Ctrl+F1) This check finds attributes set in XML files that were introduced in a version newer than the oldest version targeted by your application (with the minSdkVersion attribute). This is not an error; the application will simply ignore the attribute. However, if the attribute is important to the appearance or functionality of your application, you should consider finding an alternative way to achieve the same result with only available attributes, and then you can optionally create a copy of the layout in a layout-vNN folder which will be used on API NN or higher where you can take advantage of the newer attribute. Note: This check does not only apply to attributes. For example, some tags can be unused too, such as the new element in layouts introduced in API 21.
Upvotes: 3
Views: 693
Reputation: 2492
Found the answer (while I was waiting 90 minutes to post this question to SO..):
use xml-v25\shortcuts.xml (instead of the default xml\ folder)
Upvotes: 3