| 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/client/window_tree_client.h" | 7 #include "ui/aura/client/window_tree_client.h" |
| 8 #include "ui/aura/test/aura_test_helper.h" | 8 #include "ui/aura/test/aura_test_helper.h" |
| 9 #include "ui/aura/test/test_window_delegate.h" | 9 #include "ui/aura/test/test_window_delegate.h" |
| 10 #include "ui/aura/window.h" | 10 #include "ui/aura/window.h" |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 44 ui::GestureConfiguration::set_max_seconds_between_double_click(0.7); | 44 ui::GestureConfiguration::set_max_seconds_between_double_click(0.7); |
| 45 ui::GestureConfiguration:: | 45 ui::GestureConfiguration:: |
| 46 set_max_separation_for_gesture_touches_in_pixels(150); | 46 set_max_separation_for_gesture_touches_in_pixels(150); |
| 47 ui::GestureConfiguration:: | 47 ui::GestureConfiguration:: |
| 48 set_max_touch_down_duration_in_seconds_for_click(0.8); | 48 set_max_touch_down_duration_in_seconds_for_click(0.8); |
| 49 ui::GestureConfiguration::set_max_touch_move_in_pixels_for_click(5); | 49 ui::GestureConfiguration::set_max_touch_move_in_pixels_for_click(5); |
| 50 ui::GestureConfiguration::set_max_distance_between_taps_for_double_tap(20); | 50 ui::GestureConfiguration::set_max_distance_between_taps_for_double_tap(20); |
| 51 ui::GestureConfiguration::set_min_distance_for_pinch_scroll_in_pixels(20); | 51 ui::GestureConfiguration::set_min_distance_for_pinch_scroll_in_pixels(20); |
| 52 ui::GestureConfiguration::set_min_pinch_update_distance_in_pixels(5); | 52 ui::GestureConfiguration::set_min_pinch_update_distance_in_pixels(5); |
| 53 ui::GestureConfiguration::set_default_radius(0); | 53 ui::GestureConfiguration::set_default_radius(0); |
| 54 ui::GestureConfiguration::set_fling_acceleration_curve_coefficients( | |
| 55 0, 0.0166667f); | |
| 56 ui::GestureConfiguration::set_fling_acceleration_curve_coefficients( | |
| 57 1, -0.0238095f); | |
| 58 ui::GestureConfiguration::set_fling_acceleration_curve_coefficients( | |
| 59 2, 0.0452381f); | |
| 60 ui::GestureConfiguration::set_fling_acceleration_curve_coefficients( | |
| 61 3, 0.8f); | |
| 62 ui::GestureConfiguration::set_fling_velocity_cap(15000.0f); | 54 ui::GestureConfiguration::set_fling_velocity_cap(15000.0f); |
| 63 ui::GestureConfiguration::set_min_swipe_speed(10); | 55 ui::GestureConfiguration::set_min_swipe_speed(10); |
| 64 | 56 |
| 65 // The ContextFactory must exist before any Compositors are created. | 57 // The ContextFactory must exist before any Compositors are created. |
| 66 bool enable_pixel_output = false; | 58 bool enable_pixel_output = false; |
| 67 ui::ContextFactory* context_factory = | 59 ui::ContextFactory* context_factory = |
| 68 ui::InitializeContextFactoryForTests(enable_pixel_output); | 60 ui::InitializeContextFactoryForTests(enable_pixel_output); |
| 69 | 61 |
| 70 helper_.reset(new AuraTestHelper(&message_loop_)); | 62 helper_.reset(new AuraTestHelper(&message_loop_)); |
| 71 helper_->SetUp(context_factory); | 63 helper_->SetUp(context_factory); |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 | 99 |
| 108 bool AuraTestBase::DispatchEventUsingWindowDispatcher(ui::Event* event) { | 100 bool AuraTestBase::DispatchEventUsingWindowDispatcher(ui::Event* event) { |
| 109 ui::EventDispatchDetails details = | 101 ui::EventDispatchDetails details = |
| 110 event_processor()->OnEventFromSource(event); | 102 event_processor()->OnEventFromSource(event); |
| 111 CHECK(!details.dispatcher_destroyed); | 103 CHECK(!details.dispatcher_destroyed); |
| 112 return event->handled(); | 104 return event->handled(); |
| 113 } | 105 } |
| 114 | 106 |
| 115 } // namespace test | 107 } // namespace test |
| 116 } // namespace aura | 108 } // namespace aura |
| OLD | NEW |