Skip to content

Instantly share code, notes, and snippets.

@iampaul83
Last active August 29, 2015 14:20
Show Gist options
  • Save iampaul83/8a2dfd01c3da84c51038 to your computer and use it in GitHub Desktop.
Save iampaul83/8a2dfd01c3da84c51038 to your computer and use it in GitHub Desktop.
NS_OPTIONS demo
UIViewAnimationOptions options = UIViewAnimationOptionAutoreverse
//1 << 4
|UIViewAnimationOptionAllowUserInteraction
//1 << 1
|UIViewAnimationOptionCurveLinear;
//3 << 16
// option = 10000 | 10 | 1010000000000000000
// = 1010000000000010010 (binary)
if ((options & UIViewAnimationOptionCurveLinear) != 0) {
NSLog(@"UIViewAnimationOptionCurveLinear");
}
if ((options & UIViewAnimationOptionAllowAnimatedContent) != 0) {
NSLog(@"UIViewAnimationOptionAllowAnimatedContent");
}else {
NSLog(@"NO UIViewAnimationOptionAllowAnimatedContent");
}
[UIView transitionWithView:self.view
duration:1
options:options
animations:nil
completion:nil];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment