iOS 6.1 and Xcode 4.6, enumaration warning UIViewAnimationCurveEaseOut
Asked Answered
E

2

36

i have installed the new iOS 6.1 and Xcode 4.6, and now i have some warning of enumeration in my code, i can't resolve this:

[UIView animateWithDuration:0.4
                          delay:0.0
                        options:UIViewAnimationCurveEaseOut
                     animations:^{

                     } completion:^(BOOL finished) {}];

and this is the warning:

Implicit conversion from enumeration type 'enum UIViewAnimationCurve' to different enumeration type 'UIViewAnimationOptions' (aka 'enum UIViewAnimationOptions')

how i can solve this warning?

Euphoria answered 30/1, 2013 at 22:53 Comment(0)
H
103

You're using the wrong option value. Try UIViewAnimationOptionCurveEaseOut.

Hutchinson answered 30/1, 2013 at 22:56 Comment(3)
Came across the same problem when going through this RW tutorial: raywenderlich.com/2454/how-to-use-uiview-animation-tutorial Thanks Kevin Ballard!Pinebrook
on adding UIViewAnimationOptionCurveEaseOut getting error " Use of undeclared identifier 'animationOptions'"Discover
@Discover make sure you are passing in delay: 0.0f param before the options: param. thus it is animateWithDuration: delay: options: animations: completion:Godsey
L
2

Replace UIViewAnimationCurveEaseOut into UIViewAnimationOptionCurveEaseOut

Eg:

[UIView animateWithDuration:0.4
                          delay:0.0
                        UIViewAnimationOptionCurveEaseOut
                     animations:^{

                     } completion:^(BOOL finished) {}];
Links answered 5/2, 2015 at 13:29 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.