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 "content/renderer/render_view_impl.h" | 5 #include "content/renderer/render_view_impl.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <cmath> | 8 #include <cmath> |
9 | 9 |
10 #include "base/auto_reset.h" | 10 #include "base/auto_reset.h" |
(...skipping 30 matching lines...) Expand all Loading... |
41 #include "content/child/v8_value_converter_impl.h" | 41 #include "content/child/v8_value_converter_impl.h" |
42 #include "content/child/webmessageportchannel_impl.h" | 42 #include "content/child/webmessageportchannel_impl.h" |
43 #include "content/common/content_constants_internal.h" | 43 #include "content/common/content_constants_internal.h" |
44 #include "content/common/content_switches_internal.h" | 44 #include "content/common/content_switches_internal.h" |
45 #include "content/common/database_messages.h" | 45 #include "content/common/database_messages.h" |
46 #include "content/common/dom_storage/dom_storage_types.h" | 46 #include "content/common/dom_storage/dom_storage_types.h" |
47 #include "content/common/drag_messages.h" | 47 #include "content/common/drag_messages.h" |
48 #include "content/common/frame_messages.h" | 48 #include "content/common/frame_messages.h" |
49 #include "content/common/frame_replication_state.h" | 49 #include "content/common/frame_replication_state.h" |
50 #include "content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.h" | 50 #include "content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.h" |
| 51 #include "content/common/input/input_event_utils.h" |
51 #include "content/common/input_messages.h" | 52 #include "content/common/input_messages.h" |
52 #include "content/common/pepper_messages.h" | 53 #include "content/common/pepper_messages.h" |
53 #include "content/common/site_isolation_policy.h" | 54 #include "content/common/site_isolation_policy.h" |
54 #include "content/common/ssl_status_serialization.h" | 55 #include "content/common/ssl_status_serialization.h" |
55 #include "content/common/view_messages.h" | 56 #include "content/common/view_messages.h" |
56 #include "content/public/common/bindings_policy.h" | 57 #include "content/public/common/bindings_policy.h" |
57 #include "content/public/common/content_client.h" | 58 #include "content/public/common/content_client.h" |
58 #include "content/public/common/content_constants.h" | 59 #include "content/public/common/content_constants.h" |
59 #include "content/public/common/content_switches.h" | 60 #include "content/public/common/content_switches.h" |
60 #include "content/public/common/drop_data.h" | 61 #include "content/public/common/drop_data.h" |
(...skipping 2091 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2152 use_threaded_event_handling = compositor_deps_->IsElasticOverscrollEnabled(); | 2153 use_threaded_event_handling = compositor_deps_->IsElasticOverscrollEnabled(); |
2153 #endif | 2154 #endif |
2154 if (use_threaded_event_handling) { | 2155 if (use_threaded_event_handling) { |
2155 RenderThreadImpl* render_thread = RenderThreadImpl::current(); | 2156 RenderThreadImpl* render_thread = RenderThreadImpl::current(); |
2156 // render_thread may be NULL in tests. | 2157 // render_thread may be NULL in tests. |
2157 InputHandlerManager* input_handler_manager = | 2158 InputHandlerManager* input_handler_manager = |
2158 render_thread ? render_thread->input_handler_manager() : NULL; | 2159 render_thread ? render_thread->input_handler_manager() : NULL; |
2159 if (input_handler_manager) { | 2160 if (input_handler_manager) { |
2160 input_handler_manager->AddInputHandler( | 2161 input_handler_manager->AddInputHandler( |
2161 routing_id(), rwc->GetInputHandler(), AsWeakPtr(), | 2162 routing_id(), rwc->GetInputHandler(), AsWeakPtr(), |
2162 webkit_preferences_.enable_scroll_animator); | 2163 webkit_preferences_.enable_scroll_animator, |
| 2164 UseGestureBasedWheelScrolling()); |
2163 } | 2165 } |
2164 } | 2166 } |
2165 } | 2167 } |
2166 | 2168 |
2167 // blink::WebFrameClient ----------------------------------------------------- | 2169 // blink::WebFrameClient ----------------------------------------------------- |
2168 | 2170 |
2169 void RenderViewImpl::Repaint(const gfx::Size& size) { | 2171 void RenderViewImpl::Repaint(const gfx::Size& size) { |
2170 OnRepaint(size); | 2172 OnRepaint(size); |
2171 } | 2173 } |
2172 | 2174 |
(...skipping 1362 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3535 if (IsUseZoomForDSFEnabled()) { | 3537 if (IsUseZoomForDSFEnabled()) { |
3536 webview()->setZoomFactorForDeviceScaleFactor(device_scale_factor_); | 3538 webview()->setZoomFactorForDeviceScaleFactor(device_scale_factor_); |
3537 } else { | 3539 } else { |
3538 webview()->setDeviceScaleFactor(device_scale_factor_); | 3540 webview()->setDeviceScaleFactor(device_scale_factor_); |
3539 } | 3541 } |
3540 webview()->settings()->setPreferCompositingToLCDTextEnabled( | 3542 webview()->settings()->setPreferCompositingToLCDTextEnabled( |
3541 PreferCompositingToLCDText(compositor_deps_, device_scale_factor_)); | 3543 PreferCompositingToLCDText(compositor_deps_, device_scale_factor_)); |
3542 } | 3544 } |
3543 | 3545 |
3544 } // namespace content | 3546 } // namespace content |
OLD | NEW |