Skip to content

Instantly share code, notes, and snippets.

@eshwartm
Created September 23, 2013 10:00
Show Gist options
  • Save eshwartm/6668540 to your computer and use it in GitHub Desktop.
Save eshwartm/6668540 to your computer and use it in GitHub Desktop.
ViewController.m
- (void)viewDidLoad
{
[super viewDidLoad];
// Do any additional setup after loading the view, typically from a nib.
self.view.backgroundColor = [UIColor redColor];
NSLog(@"self.view.frame : %@", NSStringFromCGRect(self.view.frame));
NSLog(@"self.view.bounds : %@", NSStringFromCGRect(self.view.bounds));
}
- (void)didReceiveMemoryWarning
{
[super didReceiveMemoryWarning];
// Dispose of any resources that can be recreated.
}
- (BOOL) shouldAutorotate {
return YES;
}
- (void) willRotateToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation duration:(NSTimeInterval)duration {
}
- (void) didRotateFromInterfaceOrientation:(UIInterfaceOrientation)fromInterfaceOrientation {
NSLog(@"self.view.frame : %@", NSStringFromCGRect(self.view.frame));
NSLog(@"self.view.bounds : %@", NSStringFromCGRect(self.view.bounds));
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment