Created
April 12, 2011 02:39
-
-
Save veader/914818 to your computer and use it in GitHub Desktop.
Fading Animation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NSDictionary *fadeOutDict = [NSDictionary dictionaryWithObjectsAndKeys:_mainFeedViewController.view, NSViewAnimationTargetKey, NSViewAnimationFadeOutEffect, NSViewAnimationEffectKey, nil]; | |
NSAnimation *animation = [[NSViewAnimation alloc] initWithViewAnimations:[NSArray arrayWithObjects:fadeOutDict, nil]]; | |
[animation setDelegate:self]; | |
[animation setFrameRate:60.0]; | |
[animation setDuration:0.5f]; | |
[animation setAnimationBlockingMode:NSAnimationBlocking]; | |
[animation setAnimationCurve:NSAnimationEaseIn]; | |
[animation startAnimation]; | |
[animation release]; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment