In some sources I see such declarations
<item
android:id="@+id/menu_display_groups"
android:icon="@*android:drawable/ic_menu_allfriends"
android:title="@string/menu_displayGroup" />
Notice the *
@*android:
It seems to give access to internal resources. But would like to know for sure.
Also curious, if it is safe to build application with such declarations using Android 2.2 SDK, and run it on 1.5.
How can I write character & in the strings. xml? In android studio, you can simply press Alt+Enter and it will convert for you.
A string resource provides text strings for your application with optional text styling and formatting. There are three types of resources that can provide your application with strings: String. XML resource that provides a single string.
You are correct, it gives access to internal resources for platform apps. It is NOT safe to build apps with such declarations unless you are building a bundled app within a full system image.
Internal resources can (and do) change/get removed not only from platform version to platform version, but also from device to device or device version to device version.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With