Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我的可绘制文件夹中有一些图像,它们在可绘制区域中有横向版本。但是,我希望共享一些风景图像,因为用不同的名称复制文件似乎是一种浪费。是否可以为其中一个重复文件创建符号链接(快捷方式)或其他东西以防止浪费空间
下面的文件夹解释,因为我不擅长解释自己:
/drawable > image1.png > image2.png /drawable-land >image1.png <-- This image >image2.png <-- is identical to this file
在 image2.png 中,您可以使用以下内容定义 image2.xml(显然,将其放在横向文件夹中):
<bitmap xmlns:android="http://schemas.android.com/apk/res/android" android:src="@drawable/image1" />