From 8654aee859a043b47f6ec41f7c7c89d5fe9d228e Mon Sep 17 00:00:00 2001 From: Tobias Hagemann Date: Fri, 12 Dec 2014 14:45:33 +0100 Subject: [PATCH] Fixed SignUpView layout when Email is used as Username AND Additional field is being used. --- ParseUI/Classes/SignUpViewController/PFSignUpView.m | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ParseUI/Classes/SignUpViewController/PFSignUpView.m b/ParseUI/Classes/SignUpViewController/PFSignUpView.m index 461028f..d9b57cb 100644 --- a/ParseUI/Classes/SignUpViewController/PFSignUpView.m +++ b/ParseUI/Classes/SignUpViewController/PFSignUpView.m @@ -171,7 +171,7 @@ - (void)layoutSubviews { currentY = CGRectGetMaxY(frame); } - if (_emailField) { + if (_emailField && !_emailAsUsername) { CGRect frame = PFRectMakeWithSizeCenteredInRect([_emailField sizeThatFits:contentSize], contentRect); frame.origin.y = currentY; _emailField.frame = frame; @@ -226,7 +226,7 @@ - (CGSize)_contentSizeThatFits:(CGSize)boundingSize { CGSize fieldSize = [_passwordField sizeThatFits:boundingSize]; size.height += fieldSize.height; } - if (_emailField) { + if (_emailField && !_emailAsUsername) { CGSize fieldSize = [_emailField sizeThatFits:boundingSize]; size.height += fieldSize.height; }