TheHellOTrofasdasd TheHellOTrofasdasd - 1 year ago 114
Objective-C Question

Add animation to uiview moving from point A to point B

I have a gesture which action moves a UIView to point B from point A. How can I add a nice transition of the UIView moving from point A to point B. I am looking at making it slowly move from point A to point B. How would I do this? At the moment to move the item I set the frame to point B.

Answer Source

check this code and set frame what you want

[UIView animateWithDuration:0.75 animations:^{
    button.frame = CGRectMake(10, 70, 100, 100);
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download