Skip to content

Instantly share code, notes, and snippets.

@yelled3
Created October 10, 2013 11:43
Show Gist options
  • Save yelled3/6917064 to your computer and use it in GitHub Desktop.
Save yelled3/6917064 to your computer and use it in GitHub Desktop.
not sure yet...
@implementation TopViewController
- (void)viewDidLoad{
[super viewDidLoad];
if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 7) {
NSDictionary *views = @{@"topGuide": self.topLayoutGuide, @"mainView": self.view};
[self.view addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"V:[topGuide]-20-[mainView]"
options:kNilOptions
metrics:nil
views:views]];
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment