I read with interest user sunit's answer to this question about updating an EditText's hint but have been unable to find any documentation on using the method that I presume he appears to describe there: using the <selector>
element in an XML layout to dynamically adjust attributes of an EditText
at runtime when the element is focused/unfocused.
In my case I am actually more interested in adjusting the android:inputType
element (because the hint disappears for me when the inputType is specified) but adjusting the hint would work just as well.
To be clear I know how to make this change in Java code--I'm trying to find out if there is a way to specify the behavior in XML. Thanks!