Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(459)

Unified Diff: ui/keyboard/keyboard_controller.cc

Issue 2877373002: Change keyboard initialization animation from 350 ms to 100 ms (Closed)
Patch Set: Merge branch 'master' of https://chromium.googlesource.com/chromium/src into animation-change Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/keyboard/keyboard_controller.cc
diff --git a/ui/keyboard/keyboard_controller.cc b/ui/keyboard/keyboard_controller.cc
index c5569e3d4cdaa9518215263079495792a6ef1ee8..5baa7692e3f5ac0525b38a7b60c0ca20ce4230c8 100644
--- a/ui/keyboard/keyboard_controller.cc
+++ b/ui/keyboard/keyboard_controller.cc
@@ -46,8 +46,7 @@ namespace {
const int kHideKeyboardDelayMs = 100;
// The virtual keyboard show/hide animation duration.
-const int kShowAnimationDurationMs = 350;
-const int kHideAnimationDurationMs = 100;
+const int kAnimationDurationMs = 100;
// The opacity of virtual keyboard container when show animation starts or
// hide animation finishes. This cannot be zero because we call Show() on the
@@ -269,7 +268,7 @@ void KeyboardController::HideKeyboard(HideReason reason) {
ui::ScopedLayerAnimationSettings settings(container_animator);
settings.SetTweenType(gfx::Tween::FAST_OUT_LINEAR_IN);
settings.SetTransitionDuration(
- base::TimeDelta::FromMilliseconds(kHideAnimationDurationMs));
+ base::TimeDelta::FromMilliseconds(kAnimationDurationMs));
gfx::Transform transform;
transform.Translate(0, kAnimationDistance);
container_->SetTransform(transform);
@@ -499,7 +498,7 @@ void KeyboardController::ShowKeyboardInternal(int64_t display_id) {
ui::ScopedLayerAnimationSettings settings(container_animator);
settings.SetTweenType(gfx::Tween::LINEAR_OUT_SLOW_IN);
settings.SetTransitionDuration(
- base::TimeDelta::FromMilliseconds(kShowAnimationDurationMs));
+ base::TimeDelta::FromMilliseconds(kAnimationDurationMs));
container_->SetTransform(gfx::Transform());
container_->layer()->SetOpacity(1.0);
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698