Detect when a user clicks the paste button in a UITextView

前端 未结 4 1554
孤街浪徒
孤街浪徒 2021-01-02 23:06

I am having quite a issue trying to change the cut/copy/paste behavior of the UITextView. What I want to achieve is: detect when the user has pasted some text

4条回答
  •  不知归路
    2021-01-02 23:21

    UITextView has a view that handles the cut, copy, paste. It's UIWebDocumentView. So if UITextView is the first responder, UIWebDocumentView will get it first instead of your implementation. I would like to overwrite these functions so this is very frustrating.

提交回复
热议问题