Android copy selected text in webview -


i want copy selected text in android webview, tried many methods nothing done. :

 android.text.clipboardmanager clipboard = (android.text.clipboardmanager) getsystemservice(context.clipboard_service);    keyevent shiftpressevent = new keyevent(0, 0,                keyevent.action_down,                keyevent.keycode_shift_left, 0, 0);             shiftpressevent.dispatch(webview);              if(clipboard!=null)             {               string text = clipboard.gettext().tostring();               toast.maketext(this, "select_text_now     "+text, toast.length_long).show();             } 

many thanks;

according link
copy text in webview in android 2.3 , below copy functionality in webview available default in android 3.0 , above,
and may information may help, android: how select texts webview
edit
override text selection post may
override onlongtouch in webview, keep text selection


Comments

Popular posts from this blog

commonjs - How to write a typescript definition file for a node module that exports a function? -

openid - Okta: Failed to get authorization code through API call -

ios - Change Storyboard View using Seague -