OLD | NEW |
---|---|
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "content/child/webkitplatformsupport_child_impl.h" | 5 #include "content/child/webkitplatformsupport_child_impl.h" |
6 | 6 |
7 #include "base/memory/discardable_memory.h" | 7 #include "base/memory/discardable_memory.h" |
8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
9 #include "base/synchronization/waitable_event.h" | 9 #include "base/synchronization/waitable_event.h" |
10 #include "content/child/web_discardable_memory_impl.h" | 10 #include "content/child/web_discardable_memory_impl.h" |
11 #include "third_party/WebKit/public/platform/WebWaitableEvent.h" | 11 #include "third_party/WebKit/public/platform/WebWaitableEvent.h" |
12 #include "third_party/WebKit/public/web/WebInputEvent.h" | 12 #include "third_party/WebKit/public/web/WebInputEvent.h" |
ddorwin
2014/02/12 23:33:46
This is now the only public/web/ include left in t
| |
13 #include "webkit/child/fling_curve_configuration.h" | 13 #include "webkit/child/fling_curve_configuration.h" |
14 #include "webkit/child/webthread_impl.h" | 14 #include "webkit/child/webthread_impl.h" |
15 #include "webkit/child/worker_task_runner.h" | 15 #include "webkit/child/worker_task_runner.h" |
16 | 16 |
17 #if defined(OS_ANDROID) | 17 #if defined(OS_ANDROID) |
18 #include "webkit/child/fling_animator_impl_android.h" | 18 #include "webkit/child/fling_animator_impl_android.h" |
19 #endif | 19 #endif |
20 | 20 |
21 using blink::WebFallbackThemeEngine; | 21 using blink::WebFallbackThemeEngine; |
22 using blink::WebThemeEngine; | 22 using blink::WebThemeEngine; |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
63 const std::vector<float>& new_touchscreen) { | 63 const std::vector<float>& new_touchscreen) { |
64 fling_curve_configuration_->SetCurveParameters(new_touchpad, new_touchscreen); | 64 fling_curve_configuration_->SetCurveParameters(new_touchpad, new_touchscreen); |
65 } | 65 } |
66 | 66 |
67 blink::WebGestureCurve* | 67 blink::WebGestureCurve* |
68 WebKitPlatformSupportChildImpl::createFlingAnimationCurve( | 68 WebKitPlatformSupportChildImpl::createFlingAnimationCurve( |
69 int device_source, | 69 int device_source, |
70 const blink::WebFloatPoint& velocity, | 70 const blink::WebFloatPoint& velocity, |
71 const blink::WebSize& cumulative_scroll) { | 71 const blink::WebSize& cumulative_scroll) { |
72 #if defined(OS_ANDROID) | 72 #if defined(OS_ANDROID) |
73 return webkit_glue::FlingAnimatorImpl::CreateAndroidGestureCurve(velocity, | 73 return webkit_glue::FlingAnimatorImpl::CreateAndroidGestureCurve( |
74 cumulative_scroll); | 74 velocity, cumulative_scroll); |
75 #endif | 75 #endif |
76 | 76 |
77 if (device_source == blink::WebGestureEvent::Touchscreen) | 77 if (device_source == blink::WebGestureEvent::Touchscreen) |
ddorwin
2014/02/12 23:33:46
The above include is needed here.
Should there be
abarth-chromium
2014/02/12 23:37:24
Yes. It looks like this code is cheating by using
ddorwin
2014/02/12 23:49:31
Filed http://crbug.com/343327.
| |
78 return fling_curve_configuration_->CreateForTouchScreen(velocity, | 78 return fling_curve_configuration_->CreateForTouchScreen(velocity, |
79 cumulative_scroll); | 79 cumulative_scroll); |
80 | 80 |
81 return fling_curve_configuration_->CreateForTouchPad(velocity, | 81 return fling_curve_configuration_->CreateForTouchPad(velocity, |
82 cumulative_scroll); | 82 cumulative_scroll); |
83 } | 83 } |
84 | 84 |
85 blink::WebThread* WebKitPlatformSupportChildImpl::createThread( | 85 blink::WebThread* WebKitPlatformSupportChildImpl::createThread( |
86 const char* name) { | 86 const char* name) { |
87 return new webkit_glue::WebThreadImpl(name); | 87 return new webkit_glue::WebThreadImpl(name); |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
142 } | 142 } |
143 | 143 |
144 // static | 144 // static |
145 void WebKitPlatformSupportChildImpl::DestroyCurrentThread(void* thread) { | 145 void WebKitPlatformSupportChildImpl::DestroyCurrentThread(void* thread) { |
146 webkit_glue::WebThreadImplForMessageLoop* impl = | 146 webkit_glue::WebThreadImplForMessageLoop* impl = |
147 static_cast<webkit_glue::WebThreadImplForMessageLoop*>(thread); | 147 static_cast<webkit_glue::WebThreadImplForMessageLoop*>(thread); |
148 delete impl; | 148 delete impl; |
149 } | 149 } |
150 | 150 |
151 } // namespace content | 151 } // namespace content |
OLD | NEW |