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

Side by Side Diff: content/renderer/gpu/input_handler_wrapper.cc

Issue 52663003: Remove all fling related stuff from the renderer assuming that browser side Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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/gpu/input_handler_wrapper.h" 5 #include "content/renderer/gpu/input_handler_wrapper.h"
6 6
7 #include "base/message_loop/message_loop_proxy.h" 7 #include "base/message_loop/message_loop_proxy.h"
8 #include "content/renderer/gpu/input_event_filter.h" 8 #include "content/renderer/gpu/input_event_filter.h"
9 #include "content/renderer/gpu/input_handler_manager.h" 9 #include "content/renderer/gpu/input_handler_manager.h"
10 #include "third_party/WebKit/public/platform/Platform.h"
11 10
12 namespace content { 11 namespace content {
13 12
14 InputHandlerWrapper::InputHandlerWrapper( 13 InputHandlerWrapper::InputHandlerWrapper(
15 InputHandlerManager* input_handler_manager, 14 InputHandlerManager* input_handler_manager,
16 int routing_id, 15 int routing_id,
17 const scoped_refptr<base::MessageLoopProxy>& main_loop, 16 const scoped_refptr<base::MessageLoopProxy>& main_loop,
18 const base::WeakPtr<cc::InputHandler>& input_handler, 17 const base::WeakPtr<cc::InputHandler>& input_handler,
19 const base::WeakPtr<RenderViewImpl>& render_view_impl) 18 const base::WeakPtr<RenderViewImpl>& render_view_impl)
20 : input_handler_manager_(input_handler_manager), 19 : input_handler_manager_(input_handler_manager),
21 routing_id_(routing_id), 20 routing_id_(routing_id),
22 input_handler_proxy_(input_handler.get()), 21 input_handler_proxy_(input_handler.get()),
23 main_loop_(main_loop), 22 main_loop_(main_loop),
24 render_view_impl_(render_view_impl) { 23 render_view_impl_(render_view_impl) {
25 input_handler_proxy_.SetClient(this); 24 input_handler_proxy_.SetClient(this);
26 } 25 }
27 26
28 InputHandlerWrapper::~InputHandlerWrapper() { 27 InputHandlerWrapper::~InputHandlerWrapper() {
29 input_handler_proxy_.SetClient(NULL); 28 input_handler_proxy_.SetClient(NULL);
30 } 29 }
31 30
32 void InputHandlerWrapper::TransferActiveWheelFlingAnimation(
33 const WebKit::WebActiveWheelFlingParameters& params) {
34 main_loop_->PostTask(
35 FROM_HERE,
36 base::Bind(&RenderViewImpl::TransferActiveWheelFlingAnimation,
37 render_view_impl_,
38 params));
39 }
40
41 void InputHandlerWrapper::WillShutdown() { 31 void InputHandlerWrapper::WillShutdown() {
42 input_handler_manager_->RemoveInputHandler(routing_id_); 32 input_handler_manager_->RemoveInputHandler(routing_id_);
43 } 33 }
44 34
45 WebKit::WebGestureCurve* InputHandlerWrapper::CreateFlingAnimationCurve(
46 int deviceSource,
47 const WebKit::WebFloatPoint& velocity,
48 const WebKit::WebSize& cumulative_scroll) {
49 return WebKit::Platform::current()->createFlingAnimationCurve(
50 deviceSource, velocity, cumulative_scroll);
51 }
52
53 void InputHandlerWrapper::DidOverscroll(const cc::DidOverscrollParams& params) { 35 void InputHandlerWrapper::DidOverscroll(const cc::DidOverscrollParams& params) {
54 input_handler_manager_->DidOverscroll(routing_id_, params); 36 input_handler_manager_->DidOverscroll(routing_id_, params);
55 } 37 }
56 38
57 } // namespace content 39 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/gpu/input_handler_wrapper.h ('k') | content/renderer/gpu/render_widget_compositor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698