[Solved] I am using editText for password field in android. How to show the password visible for few seconds and then mask it with asterisk symbol?


more simple way use TextInputLayout

compile design library to your dependecies

compile "com.android.support:design:26.0.+"

TextInputLayout
Layout which wraps an EditText (or descendant) to show a floating label when the hint is hidden due to the user inputting text.

<android.support.design.widget.TextInputLayout
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    app:passwordToggleEnabled="true">

    <android.support.design.widget.TextInputEditText
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:hint="Enter EMail Address"
        android:inputType="textPassword"/>
</android.support.design.widget.TextInputLayout>

0

solved I am using editText for password field in android. How to show the password visible for few seconds and then mask it with asterisk symbol?