0

I want to handle copy/select/selectAll/Patse options of UIResponderStandardEditActions in webview. but i am facing problem, the copy action never called and also i observed that , in function((I have webview where i am displaying text using TTStyledTextLabel)..

canPerformAction:(SEL)action withSender:(id)sender

The copy: action never comes..but i do see that all other options like select , selectAll and cut actions getting called, even though the copy action never called in above function when i select text in webview the copy action is enabled but action never gets called..

Toseef Khilji
  • 17,192
  • 12
  • 80
  • 121
  • You can start with the [solution](http://stackoverflow.com/a/29335786/2066428) to change `canPerformAction:withSender:` implementation and extend it to all `UIResponderStandardEditActions` – malex Aug 28 '16 at 19:35

1 Answers1

0

Have you solved your problem yet? If you did please post your solution. I'm having the same problem with the paste function.

The solution I found, and I know it's not ideal, its to detect the events through javascript.

I use javascript to detect when a paste happens, call my objectiveC function to work with the data, and call a JS function from the objectiveC to paste the content on the webview.

Leonardo
  • 1,740
  • 18
  • 27