標(biāo)簽(空格分隔): ios 剪切板
1.文本UILable設(shè)置可以交互
2.添加長按手勢
[jobInfoText addGestureRecognizer:longPress];```
3.響應(yīng)`長按手勢`
```- (void)copyText:(UILongPressGestureRecognizer *)gesture
{
if (gesture.state ==UIGestureRecognizerStateBegan)
{
UIPasteboard *pasteboard = [UIPasteboardgeneralPasteboard];
[pasteboard setString:self.jobInfoText.text];
}
}```