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

Unified Diff: sky/engine/core/frame/LocalFrame.cpp

Issue 680703002: Remove 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/frame/FrameView.cpp ('k') | sky/engine/core/frame/PinchViewport.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/engine/core/frame/LocalFrame.cpp
diff --git a/sky/engine/core/frame/LocalFrame.cpp b/sky/engine/core/frame/LocalFrame.cpp
index c1eb350f9ce527abf3a45a3dd7eca2e37582d45f..bf62a02b3f3e80945974b067783c4397e9340390 100644
--- a/sky/engine/core/frame/LocalFrame.cpp
+++ b/sky/engine/core/frame/LocalFrame.cpp
@@ -383,15 +383,6 @@ void LocalFrame::setPageAndTextZoomFactors(float pageZoomFactor, float textZoomF
if (!document)
return;
- if (m_pageZoomFactor != pageZoomFactor) {
- if (FrameView* view = this->view()) {
- // Update the scroll position when doing a full page zoom, so the content stays in relatively the same position.
- LayoutPoint scrollPosition = view->scrollPosition();
- float percentDifference = (pageZoomFactor / m_pageZoomFactor);
- view->setScrollPosition(IntPoint(scrollPosition.x() * percentDifference, scrollPosition.y() * percentDifference));
- }
- }
-
m_pageZoomFactor = pageZoomFactor;
m_textZoomFactor = textZoomFactor;
« no previous file with comments | « sky/engine/core/frame/FrameView.cpp ('k') | sky/engine/core/frame/PinchViewport.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698