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

Side by Side Diff: content/renderer/render_view_impl.cc

Issue 12582009: Implement windows mousewheel scroll by page functionality (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: fix scroll distance calculation to more closely match windows behavior Created 7 years, 9 months 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) 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 2538 matching lines...) Expand 10 before | Expand all | Expand 10 after
2549 mouse_lock_dispatcher_->UnlockMouse(webwidget_mouse_lock_target_.get()); 2549 mouse_lock_dispatcher_->UnlockMouse(webwidget_mouse_lock_target_.get());
2550 } 2550 }
2551 2551
2552 bool RenderViewImpl::isPointerLocked() { 2552 bool RenderViewImpl::isPointerLocked() {
2553 return mouse_lock_dispatcher_->IsMouseLockedTo( 2553 return mouse_lock_dispatcher_->IsMouseLockedTo(
2554 webwidget_mouse_lock_target_.get()); 2554 webwidget_mouse_lock_target_.get());
2555 } 2555 }
2556 2556
2557 void RenderViewImpl::didActivateCompositor(int input_handler_identifier) { 2557 void RenderViewImpl::didActivateCompositor(int input_handler_identifier) {
2558 #if !defined(OS_MACOSX) // many events are unhandled - http://crbug.com/138003 2558 #if !defined(OS_MACOSX) // many events are unhandled - http://crbug.com/138003
2559 #if !defined(OS_WIN) // http://crbug.com/160122
2560 InputHandlerManager* input_handler_manager = 2559 InputHandlerManager* input_handler_manager =
2561 RenderThreadImpl::current()->input_handler_manager(); 2560 RenderThreadImpl::current()->input_handler_manager();
2562 if (input_handler_manager) 2561 if (input_handler_manager)
2563 input_handler_manager->AddInputHandler( 2562 input_handler_manager->AddInputHandler(
2564 routing_id_, input_handler_identifier, AsWeakPtr()); 2563 routing_id_, input_handler_identifier, AsWeakPtr());
2565 #endif 2564 #endif
2566 #endif
2567 2565
2568 RenderWidget::didActivateCompositor(input_handler_identifier); 2566 RenderWidget::didActivateCompositor(input_handler_identifier);
2569 2567
2570 FOR_EACH_OBSERVER(RenderViewObserver, observers_, 2568 FOR_EACH_OBSERVER(RenderViewObserver, observers_,
2571 DidActivateCompositor(input_handler_identifier)); 2569 DidActivateCompositor(input_handler_identifier));
2572 } 2570 }
2573 2571
2574 void RenderViewImpl::didHandleGestureEvent( 2572 void RenderViewImpl::didHandleGestureEvent(
2575 const WebGestureEvent& event, 2573 const WebGestureEvent& event,
2576 bool event_cancelled) { 2574 bool event_cancelled) {
(...skipping 3942 matching lines...) Expand 10 before | Expand all | Expand 10 after
6519 TransportDIB* dib = TransportDIB::CreateWithHandle(dib_handle); 6517 TransportDIB* dib = TransportDIB::CreateWithHandle(dib_handle);
6520 RenderProcess::current()->ReleaseTransportDIB(dib); 6518 RenderProcess::current()->ReleaseTransportDIB(dib);
6521 } 6519 }
6522 6520
6523 void RenderViewImpl::DidCommitCompositorFrame() { 6521 void RenderViewImpl::DidCommitCompositorFrame() {
6524 RenderWidget::DidCommitCompositorFrame(); 6522 RenderWidget::DidCommitCompositorFrame();
6525 FOR_EACH_OBSERVER(RenderViewObserver, observers_, DidCommitCompositorFrame()); 6523 FOR_EACH_OBSERVER(RenderViewObserver, observers_, DidCommitCompositorFrame());
6526 } 6524 }
6527 6525
6528 } // namespace content 6526 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698