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

Unified Diff: sky/engine/core/events/MouseRelatedEvent.cpp

Issue 677223002: Remove some more frame-level scrolling machinery. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years, 2 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
« no previous file with comments | « sky/engine/core/dom/TreeScope.cpp ('k') | sky/engine/core/frame/FrameView.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/engine/core/events/MouseRelatedEvent.cpp
diff --git a/sky/engine/core/events/MouseRelatedEvent.cpp b/sky/engine/core/events/MouseRelatedEvent.cpp
index 9b7f32ec3a37666eff6bb73e64b3b17a7e226d55..5a4fae3a9a3cbbe35b43200ba73f0d9bc49803b1 100644
--- a/sky/engine/core/events/MouseRelatedEvent.cpp
+++ b/sky/engine/core/events/MouseRelatedEvent.cpp
@@ -38,20 +38,6 @@ MouseRelatedEvent::MouseRelatedEvent()
{
}
-static LayoutSize contentsScrollOffset(AbstractView* abstractView)
-{
- if (!abstractView)
- return LayoutSize();
- LocalFrame* frame = abstractView->frame();
- if (!frame)
- return LayoutSize();
- FrameView* frameView = frame->view();
- if (!frameView)
- return LayoutSize();
- float scaleFactor = frame->pageZoomFactor();
- return LayoutSize(frameView->scrollX() / scaleFactor, frameView->scrollY() / scaleFactor);
-}
-
MouseRelatedEvent::MouseRelatedEvent(const AtomicString& eventType, bool canBubble, bool cancelable, PassRefPtrWillBeRawPtr<AbstractView> abstractView,
int detail, const IntPoint& screenLocation, const IntPoint& windowLocation,
const IntPoint& movementDelta,
@@ -99,7 +85,8 @@ void MouseRelatedEvent::initCoordinates(const LayoutPoint& clientLocation)
// Set up initial values for coordinates.
// Correct values are computed lazily, see computeRelativePosition.
m_clientLocation = clientLocation;
- m_pageLocation = clientLocation + contentsScrollOffset(view());
+ // FIXME(sky): We don't need this anymore?
+ m_pageLocation = clientLocation;
m_layerLocation = m_pageLocation;
m_offsetLocation = m_pageLocation;
« no previous file with comments | « sky/engine/core/dom/TreeScope.cpp ('k') | sky/engine/core/frame/FrameView.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698