Skip to content

Instantly share code, notes, and snippets.

@Rich86man
Created May 2, 2013 05:17
Show Gist options
  • Save Rich86man/5500278 to your computer and use it in GitHub Desktop.
Save Rich86man/5500278 to your computer and use it in GitHub Desktop.
This seems to work too
- (void)loadGroup:(NSString *)group {
// If the groups the same, no need to reload.
if ([_currentGroup isEqualToString:group]) {
return;
}
_currentGroup = group;
NSLog(@"%@: %@", _currentGroup, [_appearanceContainer[_currentGroup] backgroundColor]);
[UIView animateWithDuration:kAnimationDuration animations:^{
_sharedInstance.frame = CGRectMake(0, _parentView.frame.size.height, _parentView.frame.size.width, kAppBarTotalHeight);
} completion:^(BOOL finished) {
self.backgroundColor = [_appearanceContainer[_currentGroup] backgroundColor];
[self showMinimalAppBar];
[self setButtonFrames];
[self setNeedsDisplay];
}];
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment