OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "ui/aura/test/aura_test_base.h" | 5 #include "ui/aura/test/aura_test_base.h" |
6 | 6 |
7 #include "ui/aura/test/aura_test_helper.h" | 7 #include "ui/aura/test/aura_test_helper.h" |
8 #include "ui/aura/window.h" | 8 #include "ui/aura/window.h" |
9 #include "ui/base/gestures/gesture_configuration.h" | 9 #include "ui/base/gestures/gesture_configuration.h" |
10 #include "ui/base/ime/text_input_test_support.h" | 10 #include "ui/base/ime/text_input_test_support.h" |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
47 ui::GestureConfiguration::set_rail_start_proportion(2); | 47 ui::GestureConfiguration::set_rail_start_proportion(2); |
48 ui::GestureConfiguration::set_default_radius(0); | 48 ui::GestureConfiguration::set_default_radius(0); |
49 ui::GestureConfiguration::set_fling_acceleration_curve_coefficients( | 49 ui::GestureConfiguration::set_fling_acceleration_curve_coefficients( |
50 0, 0.0166667f); | 50 0, 0.0166667f); |
51 ui::GestureConfiguration::set_fling_acceleration_curve_coefficients( | 51 ui::GestureConfiguration::set_fling_acceleration_curve_coefficients( |
52 1, -0.0238095f); | 52 1, -0.0238095f); |
53 ui::GestureConfiguration::set_fling_acceleration_curve_coefficients( | 53 ui::GestureConfiguration::set_fling_acceleration_curve_coefficients( |
54 2, 0.0452381f); | 54 2, 0.0452381f); |
55 ui::GestureConfiguration::set_fling_acceleration_curve_coefficients( | 55 ui::GestureConfiguration::set_fling_acceleration_curve_coefficients( |
56 3, 0.8f); | 56 3, 0.8f); |
| 57 ui::GestureConfiguration::set_fling_velocity_cap(15000.0f); |
57 | 58 |
58 helper_.reset(new AuraTestHelper(&message_loop_)); | 59 helper_.reset(new AuraTestHelper(&message_loop_)); |
59 helper_->SetUp(); | 60 helper_->SetUp(); |
60 } | 61 } |
61 | 62 |
62 void AuraTestBase::TearDown() { | 63 void AuraTestBase::TearDown() { |
63 // Flush the message loop because we have pending release tasks | 64 // Flush the message loop because we have pending release tasks |
64 // and these tasks if un-executed would upset Valgrind. | 65 // and these tasks if un-executed would upset Valgrind. |
65 RunAllPendingInMessageLoop(); | 66 RunAllPendingInMessageLoop(); |
66 | 67 |
(...skipping 15 matching lines...) Expand all Loading... |
82 void AuraTestBase::SetDefaultParentByPrimaryRootWindow(aura::Window* window) { | 83 void AuraTestBase::SetDefaultParentByPrimaryRootWindow(aura::Window* window) { |
83 window->SetDefaultParentByRootWindow(root_window(), gfx::Rect()); | 84 window->SetDefaultParentByRootWindow(root_window(), gfx::Rect()); |
84 } | 85 } |
85 | 86 |
86 void AuraTestBase::RunAllPendingInMessageLoop() { | 87 void AuraTestBase::RunAllPendingInMessageLoop() { |
87 helper_->RunAllPendingInMessageLoop(); | 88 helper_->RunAllPendingInMessageLoop(); |
88 } | 89 } |
89 | 90 |
90 } // namespace test | 91 } // namespace test |
91 } // namespace aura | 92 } // namespace aura |
OLD | NEW |