diff --git a/Riot/Modules/Room/Views/InputToolbar/RoomActionsBar.swift b/Riot/Modules/Room/Views/InputToolbar/RoomActionsBar.swift index 0cf11e292..3f78b9cb3 100644 --- a/Riot/Modules/Room/Views/InputToolbar/RoomActionsBar.swift +++ b/Riot/Modules/Room/Views/InputToolbar/RoomActionsBar.swift @@ -99,7 +99,7 @@ import UIKit button.transform = CGAffineTransform(translationX: 0, y: self.bounds.height) } for (index, button) in actionButtons.enumerated() { - UIView.animate(withDuration: 0.38, delay: 0.05 * Double(index), usingSpringWithDamping: 0.5, initialSpringVelocity: 7, options: .curveEaseInOut) { + UIView.animate(withDuration: 0.3, delay: 0.05 * Double(index), usingSpringWithDamping: 0.45, initialSpringVelocity: 11, options: .curveEaseInOut) { button.transform = CGAffineTransform.identity } completion: { (finished) in completion?(finished) @@ -107,10 +107,12 @@ import UIKit } } else { for (index, button) in actionButtons.enumerated() { - UIView.animate(withDuration: 0.3, delay: 0.05 * Double(index), options: .curveEaseInOut) { + UIView.animate(withDuration: 0.25, delay: 0.05 * Double(index), options: .curveEaseInOut) { button.transform = CGAffineTransform(translationX: 0, y: self.bounds.height) } completion: { (finished) in - completion?(finished) + if index == self.actionButtons.count - 1 { + completion?(finished) + } } } } diff --git a/Riot/Modules/Room/Views/InputToolbar/RoomInputToolbarView.m b/Riot/Modules/Room/Views/InputToolbar/RoomInputToolbarView.m index 5997ce8bb..c76bbd038 100644 --- a/Riot/Modules/Room/Views/InputToolbar/RoomInputToolbarView.m +++ b/Riot/Modules/Room/Views/InputToolbar/RoomInputToolbarView.m @@ -201,7 +201,7 @@ const double RoomInputToolbarViewContextBarHeight = 30; if (self.mainToolbarHeightConstraint.constant != updatedHeight) { - [UIView animateWithDuration:.3 animations:^{ + [UIView animateWithDuration:.15 animations:^{ self.mainToolbarHeightConstraint.constant = updatedHeight; [self layoutIfNeeded];