在Android Studio 1.3及更高版本中隐藏android.R资源

在Android Studio 1.3及更高版本中隐藏android.R资源

问题描述:

是否可以将Android Studio配置为仅显示 project 文件夹中的@drawable资源?

Is it possible to configure Android Studio to display only the @drawable resources that are inside the project folder?

我正在从事的项目是一个行业项目,很少要求我使用R资源.

The project I'm working on is an Industry project and rarely requires me to use R resources.

在AS的代码完成"部分中,我没有找到任何允许隐藏SDK资源并使用app/lib资源的设置:

Looking through the AS's 'Code Completion' section, I didn't find any setting which allows to hide the SDK resources and use the app/lib resources instead:

StefMa提到的最近实现的功能可能对您没有帮助,因为它以另一种方式起作用:它允许库开发人员从aar包中隐藏一些资源,并仅显示资源的一部分,即公共资源. Chris Banes在此处上做了很好的介绍.

The recently implemented feature, mentioned by StefMa, probably will not help you as it works the other way: it allows library developers to hide some of the resources from the aar package and show only selected portion of resources, aka public recources. Chris Banes made a good intro in this feature here.