我禁用了针对特定 XML 文件的 Android Lint 警告“HardcodedText”(它用于数字小键盘,其中包含数字的固定文本)。
我找不到在这个文件上重新启用它的方法('Restore Defaults' 左右),无论是在 Windows > Preferences > Android > Lint Error Checking 还是 项目 > 属性 > Android Lint 首选项。
关于如何在文件级别重新启用已禁用的警告有任何想法吗?
最佳答案
自己发现:Lint 将文件“lint.xml”放入包含依赖项的项目中。
<lint>
<issue id="UnusedResources">
<ignore path="res\layout\my_layout.xml" />
</issue>
<lint>
不幸的是,编辑和保存这个文件是不够的。您必须关闭并重新打开项目甚至 Eclipse。
HTH 其他有同样问题的人....
关于android - 如何在文件级别重新启用已禁用的 Android Lint 警告,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10069936/