我里面有
AutoCompleteTextView
TextInputLayout
。从下拉菜单中选择项目时,如何消除 AutoCompleteTextView 中的涟漪效应。
我说的是小部件上的波纹,而不是下拉菜单内的波纹。
你可能有这样的东西
ArrayAdapter<String> adapter = new ArrayAdapter<String> (this,android.R.layout.select_dialog_item,language);
将 android.R.layout.select_dialog_item
更改为您的服装 xml
有2个解决方案
在主题中使用 colorControlHighlight 属性,并使用样式将其应用到 TextInputLayout。
在MaterialAutoCompleteTextView中设置
android:inputType="textNoSuggestions"
。基本上我们需要设置任何可编辑的 inputType,那么波纹就不会出现。