BGButton * copyButton =[BGButton buttonWithType:UIButtonTypeCustom];
copyButton.backgroundColor= [UIColorclearColor];
[copyButtonaddTarget:self action:@selector(copyClick) forControlEvents:UIControlEventTouchUpInside];
[self.contentViewaddSubview:copyButton];
- (void)copyClick{
UIPasteboard * pasteboard = [UIPasteboard generalPasteboard];
pasteboard.string=self.leftThirdLabel.text;
//设置HUD的Style
[SVProgressHUD setDefaultStyle:(SVProgressHUDStyleDark)];
if(pasteboard ==nil) {
[SVProgressHUD showErrorWithStatus:BGLocaltring(@"Copy failed")];
}else{
[SVProgressHUD showSuccessWithStatus:BGLocaltring(@"Copy successfully")];
}
[SVProgressHUD dismissWithDelay:1.0];
}