Adjust size of name and email textfields in feedback UI

Now resizes with device rotation on non iPad and uses max width on both device types.
This commit is contained in:
Andreas Linde 2013-06-04 15:10:57 +02:00
parent d21b7b001c
commit 84e63761dc

View File

@ -200,7 +200,10 @@
cell.selectionStyle = UITableViewCellSelectionStyleNone; cell.selectionStyle = UITableViewCellSelectionStyleNone;
cell.backgroundColor = [UIColor whiteColor]; cell.backgroundColor = [UIColor whiteColor];
UITextField *textField = [[UITextField alloc] initWithFrame:CGRectMake(110, 10, 185, 30)]; UITextField *textField = [[UITextField alloc] initWithFrame:CGRectMake(110, 10, self.view.frame.size.width - 110 - 35, 30)];
if (UI_USER_INTERFACE_IDIOM() != UIUserInterfaceIdiomPad) {
textField.autoresizingMask = UIViewAutoresizingFlexibleWidth;
}
textField.adjustsFontSizeToFitWidth = YES; textField.adjustsFontSizeToFitWidth = YES;
textField.textColor = [UIColor blackColor]; textField.textColor = [UIColor blackColor];
textField.backgroundColor = [UIColor lightGrayColor]; textField.backgroundColor = [UIColor lightGrayColor];