按钮翻译和规模的动画有两个不同的标题
问题描述:
我需要使用翻译和规模animation.I现在用这个code.Button标题是“添加音乐”按钮翻译和规模的动画有两个不同的标题
[UIView animateWithDuration:3 animations:^{
waterMarkButton.transform = CGAffineTransformMakeScale(-1, 1);
}];
这是很好的转变为动态显示按钮,但我的标题也转换了,但是当转换时我需要标题“删除”。我该怎么做?
答
您可以动画的标题,例如:
[UIView transitionWithView:waterMarkBduration:1 options:UIViewAnimationOptionTransitionFlipFromRight animations:^{
[waterMarkButton setTitle:newText forState:UIControlStateNormal];
} completion:nil];
非常感谢你。 – Saad
[transitionWithView:waterMarkButton setTitle:newText forState:UIControlStateNormal];越来越错误transitionWithView没有宣布@ kunal K Shah – Saad
我编辑了答案。 –