我在基于消息的 iPhone 应用程序中工作。在我的应用程序中看起来像 iMessage 原生 iOS 应用程序。I made Bubbles with used UIImageView and UILabel. I made UILabel as clickable and showing Copy option. It is working fine when the message input UITextView is not in active.
1. I can show the "Copy" option when we clicking UILabel and the UITextView is not becomeFirstResponder.
2. When the user clicking the MessageTextView (UITextView) from the bottom of the screen the UITextView becoming first responder and keyboard is showing now. In this scenario if the user clicking the messabe bubble (UILabel) the UIMenuItem showing "Paste" on the bubble instead of "Copy".
3. If i click "Paste" from the bubble UIMenuItem already copied text will be pasting in UITextView. So the control fully in UITextView UIMenuController not activated in UILabel. So i cleared the text from UIPateBoard when the user clicking the Bubble (UILabel).
4. Now the UIMenuController not showing up even [self becomeFirstResponder]; not becoming in UILabel class.
原因是当 UITextView 处于 becomeFirstResponder 中时,控件完全在其中。不来 UILabel。你能帮我解决这个问题吗?
How to show UIMenuItem "Copy" when the user clicking UILabel if the keyboard is in visible the control is in UITextView?
你能帮我解决这个问题吗?我在这个问题上花了两天时间。提前致谢。