I am trying to resize the objects in a UIView when the device is rotated without hard coding the width and height. In this code how would I get the newWidth
and newHeight
?
- (void)willAnimateRotationToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation duration:(NSTimeInterval)duration {
child.frame = CGRectMake(10, 10, newWidth - 20, newHeight - 20);
}