Chromium Code Reviews| Index: remoting/ios/app/client_connection_view_controller.mm |
| diff --git a/remoting/ios/app/client_connection_view_controller.mm b/remoting/ios/app/client_connection_view_controller.mm |
| index 5426c122ae79df7e0fb14567d496be183f716b15..108419a9465612640fabb73a34246276b126b8c5 100644 |
| --- a/remoting/ios/app/client_connection_view_controller.mm |
| +++ b/remoting/ios/app/client_connection_view_controller.mm |
| @@ -31,6 +31,8 @@ static const CGFloat kMargin = 20.f; |
| static const CGFloat kBarHeight = 58.f; |
| +static const CGFloat kKeyboardAnimationTime = 0.3; |
|
Yuwei
2017/05/15 19:38:07
0.3f? Although the compiler might be clever enough
nicholss
2017/05/15 23:06:11
##.f should be the same as ##.0, but style wise I
Yuwei
2017/05/16 00:47:30
Technically speaking 0.3 is a double precision flo
|
| + |
| @interface ClientConnectionViewController ()<PinEntryDelegate> { |
| UIImageView* _iconView; |
| MDCActivityIndicator* _activityIndicator; |
| @@ -175,12 +177,12 @@ static const CGFloat kBarHeight = 58.f; |
| - (void)keyboardWillShow:(NSNotification*)notification { |
| CGSize keyboardSize = |
| - [[[notification userInfo] objectForKey:UIKeyboardFrameBeginUserInfoKey] |
| + [[[notification userInfo] objectForKey:UIKeyboardFrameEndUserInfoKey] |
| CGRectValue] |
| .size; |
| [UIView |
| - animateWithDuration:0.3 |
| + animateWithDuration:kKeyboardAnimationTime |
| animations:^{ |
| CGRect f = self.view.frame; |
| CGFloat newHeight = |
| @@ -196,7 +198,7 @@ static const CGFloat kBarHeight = 58.f; |
| } |
| - (void)keyboardWillHide:(NSNotification*)notification { |
| - [UIView animateWithDuration:0.3 |
| + [UIView animateWithDuration:kKeyboardAnimationTime |
| animations:^{ |
| CGRect f = self.view.frame; |
| f.origin.y = 0.f; |