API documentation: "The icon and error message will be reset to zero if any key events cause changes to the TextView text." Although this is not so, and therefore we can consider this a mistake.
If you use inputType, for example textNoSuggestions, textEmailAddress, textPassword, the error will be canceled after entering the character. Almost as documented, but again not entirely accurate - the error remains when deleting the character. It seems like a simple workaround with addTextChangedListener and setError (null) can achieve the promised behavior.
In addition, there are reports of the loss of the icon on Android 4.2. Therefore use with caution.
gints May 11 '14 at 23:56 2014-05-11 23:56
source share