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

Unified Diff: Source/core/events/MouseRelatedEvent.cpp

Issue 967213004: Removed FrameView's windowToContents and contentsToWindow methods. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 10 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/core/events/MouseRelatedEvent.cpp
diff --git a/Source/core/events/MouseRelatedEvent.cpp b/Source/core/events/MouseRelatedEvent.cpp
index 948adcf2ce9f8950272134d1fbfb0e3e975fac84..ec5a22845e6890193b46323fc52144ca159d20cd 100644
--- a/Source/core/events/MouseRelatedEvent.cpp
+++ b/Source/core/events/MouseRelatedEvent.cpp
@@ -53,9 +53,9 @@ static LayoutSize contentsScrollOffset(AbstractView* abstractView)
}
MouseRelatedEvent::MouseRelatedEvent(const AtomicString& eventType, bool canBubble, bool cancelable, PassRefPtrWillBeRawPtr<AbstractView> abstractView,
- int detail, const IntPoint& screenLocation, const IntPoint& windowLocation,
- const IntPoint& movementDelta,
- bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, bool isSimulated)
+ int detail, const IntPoint& screenLocation, const IntPoint& rootFrameLocation,
+ const IntPoint& movementDelta,
+ bool ctrlKey, bool altKey, bool shiftKey, bool metaKey, bool isSimulated)
: UIEventWithKeyState(eventType, canBubble, cancelable, abstractView, detail, ctrlKey, altKey, shiftKey, metaKey)
, m_screenLocation(screenLocation)
, m_movementDelta(movementDelta)
@@ -68,7 +68,7 @@ MouseRelatedEvent::MouseRelatedEvent(const AtomicString& eventType, bool canBubb
if (frame && !isSimulated) {
if (FrameView* frameView = frame->view()) {
scrollPosition = frameView->scrollPosition();
- adjustedPageLocation = frameView->windowToContents(windowLocation);
+ adjustedPageLocation = frameView->rootFrameToContents(rootFrameLocation);
float scaleFactor = 1 / frame->pageZoomFactor();
if (scaleFactor != 1.0f) {
adjustedPageLocation.scale(scaleFactor, scaleFactor);

Powered by Google App Engine
This is Rietveld 408576698