@ CallSuper protected void updateBorder ( ) { boolean isFocused = input . hasFocus ( ) && ! input . isInTouchMode ( ) ; ViewUtils . setBackground ( outline , hasValidInput ? ( isFocused ? focusedOutlineBackground : normalOutlineBackground ) : errorOutlineBackground ) ; errorDescription . setVisibility ( hasValidInput ? GONE : VISIBLE ) ; requestLayout ( ) ; }
Updates the view knowing if the input is valid or not .