Background
We can use ClipboardManager to copy something to the clipboard, as such:
final ClipboardManager clipboard = (ClipboardManager) getContext().getSystemService(Context.CLIPBOARD_SERVICE);
final ClipData clipData = ClipData.newPlainText("", someTextToCopy);
clipboard.setPrimaryClip(clipData);
The problem
Thing is, this code is silent, so the user doesn't see anything that shows that the text was copied.
I could add a toast of my own, but not all devices show a toast upon text copying by the user (G2 shows temporary notes window with the added content), and even for those that do, I can't find the string that they use, and also not the translations.
Here's how it looks like on LG G2 (wait till the copy is done):
https://youtu.be/cmmJC4_7EhE?t=33
And here's how a toast is shown on another device:
https://youtu.be/9S7ud5Ux5Fg?t=49
The question
Is there a way to invoke the default clipboard copying?
I'm talking about the one that's being used on EditText (or WebView, or anywhere you can copy text from as a user), when you mark text in it and choose "copy" .
Note that I don't use it for EditText/TextView. I want to invoke the default copying, even from a button.