Eclipse和Android共享资源
初学者问题: 我有一个库项目,其中包含 raw、drawable 等文件。 我在我的项目中添加了对它的引用,该项目具有其他原始、可绘制等。
我看到库项目中的 java 文件,但看不到资源(原始、可绘制等)。
我如何添加它们? 我尝试使用“链接源”,但我无法将原始添加到原始(并且我需要对目录使用相同的名称,对吧?)
换句话说:如何将资源从库项目合并到我的主项目?
Beginners question:
I have one Library project, that has files under raw, drawable, etc.
I have added a reference to it in my project that has other raw, drawable etc.
I see the java files from the library project but not the resources (raw, drawable, etc.).
How do I add them?
I tried with "Link Source", but I can't add raw to raw (and I need to use same name for directory, right?)
IN other words: how do I merge the resources from the Library project to my main project?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
资源会自动合并,你不用担心,如果项目文件夹中有同名资源,它会优先于库资源。看看这里
http://developer.android.com/指南/开发/项目/projects-eclipse.html#SettingUpLibraryProject
Resources are automatically merged, you dont have to worry about it, if you have a resource with the same name in the project's folder, it takes priority over the library resources. Have a look at here
http://developer.android.com/guide/developing/projects/projects-eclipse.html#SettingUpLibraryProject