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

Unified Diff: Source/web/PageWidgetDelegate.cpp

Issue 197213011: Selectively disable rubber banding on mac. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
Index: Source/web/PageWidgetDelegate.cpp
diff --git a/Source/web/PageWidgetDelegate.cpp b/Source/web/PageWidgetDelegate.cpp
index 0c7ab2aa17c25b0a0554f833e9f302d36b74568d..6cb66ae413792b2483997aa5041f1655d879bb53 100644
--- a/Source/web/PageWidgetDelegate.cpp
+++ b/Source/web/PageWidgetDelegate.cpp
@@ -107,7 +107,7 @@ void PageWidgetDelegate::paint(Page* page, PageOverlayList* overlays, WebCanvas*
gc.restore();
}
-bool PageWidgetDelegate::handleInputEvent(Page* page, PageWidgetEventHandler& handler, const WebInputEvent& event)
+bool PageWidgetDelegate::handleInputEvent(Page* page, PageWidgetEventHandler& handler, const WebInputEvent& event, bool canRubberbandLeft, bool canRubberbandRight)
{
LocalFrame* frame = page ? page->mainFrame() : 0;
switch (event.type) {
@@ -139,7 +139,7 @@ bool PageWidgetDelegate::handleInputEvent(Page* page, PageWidgetEventHandler& ha
case WebInputEvent::MouseWheel:
if (!frame || !frame->view())
return false;
- return handler.handleMouseWheel(*frame, *static_cast<const WebMouseWheelEvent*>(&event));
+ return handler.handleMouseWheel(*frame, *static_cast<const WebMouseWheelEvent*>(&event), canRubberbandLeft, canRubberbandRight);
case WebInputEvent::RawKeyDown:
case WebInputEvent::KeyDown:
@@ -209,9 +209,9 @@ void PageWidgetEventHandler::handleMouseUp(LocalFrame& mainFrame, const WebMouse
mainFrame.eventHandler().handleMouseReleaseEvent(PlatformMouseEventBuilder(mainFrame.view(), event));
}
-bool PageWidgetEventHandler::handleMouseWheel(LocalFrame& mainFrame, const WebMouseWheelEvent& event)
+bool PageWidgetEventHandler::handleMouseWheel(LocalFrame& mainFrame, const WebMouseWheelEvent& event, bool canRubberbandLeft, bool canRubberbandRight)
{
- return mainFrame.eventHandler().handleWheelEvent(PlatformWheelEventBuilder(mainFrame.view(), event));
+ return mainFrame.eventHandler().handleWheelEvent(PlatformWheelEventBuilder(mainFrame.view(), event), canRubberbandLeft, canRubberbandRight);
}
bool PageWidgetEventHandler::handleTouchEvent(LocalFrame& mainFrame, const WebTouchEvent& event)

Powered by Google App Engine
This is Rietveld 408576698