I have an EditText on which I need to disable long click. On long clicking the editText the action mode set for the apps WebView pops up.
Tried adding the below code but failed.
editTextView.setLongClickable(false);
editTextView.setTextIsSelectable(false);
Also tried adding
longClickable="false"
on the layout xml.
I don't know about you, but a simple
editText.setLongClickable(false);
works as expected.You may have some other method or xml overriding it, for example:
is not the same as:
In example 1, editText's long-click will be disabled.
In example 2, editText's long-click is still enabled.
These are just java examples, there can also be xml elements to check for.
You need to check your flow or post more code.