I am on Android 3+ and I am trying to add hints to my edit text widgets. I tried adding the hint to the layout as follows...
<EditText
android:id="@+id/bar_name"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:inputType="text"
android:hint="@string/bar_name_hint"
android:imeOptions="actionNext"
/>
But when I focus on the Text box it writes over the hint instead of the hint disappearing.
I found documentation on adding a onFocus listener to the EditText, but I would like to avoid doing this programatically. The post below also mentioned using selectors but I can't find documentation on how to do that.
So what is the best way to handle this?