Skip to content

Instantly share code, notes, and snippets.

@dbrajkovic
Created March 22, 2011 16:36
Show Gist options
  • Save dbrajkovic/881521 to your computer and use it in GitHub Desktop.
Save dbrajkovic/881521 to your computer and use it in GitHub Desktop.
var thisDict;
thisDict = [CPDictionary dictionaryWithObjectsAndKeys: appLauncherView,
CPViewAnimationTargetKey,
(open) ? CPViewAnimationFadeOutEffect : CPViewAnimationFadeInEffect,
CPViewAnimationEffectKey];
[anims addObject:thisDict]; //BOOL open determines which effect will occur
animation = [[CPViewAnimation alloc] initWithViewAnimations:anims];
//[animation setAnimationBlockingMode:CPAnimationBlocking];
[animation setDuration:1.0]; // default is 0.5 (seconds)
[animation startAnimation];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment