Created
March 25, 2015 11:20
-
-
Save SelvinPL/e0a9ea5c2ccd48ea7d95 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- values/attr.xml --> | |
<?xml version="1.0" encoding="utf-8"?> | |
<resources> | |
<attr name="my_image" format="reference" /> | |
</resources> | |
<!-- values/styles.xml --> | |
<style name="MyThemeBase" parent="@style/MyThemeBaseBase"> | |
<item name="my_image">@drawable/my_image_en</item> | |
</style> | |
<!-- values-fr/styles.xml --> | |
<style name="MyTheme" parent="@style/MyThemeBase"> | |
<item name="my_image">@drawable/my_image_fr_es</item> | |
</style> | |
<!-- values-es/styles.xml --> | |
<style name="MyTheme" parent="@style/MyThemeBase"> | |
<item name="my_image">@drawable/my_image_fr_es</item> | |
</style> | |
<!-- usage (some layout) --> | |
<ImageView src="?attr/my_image" /> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment