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

Unified Diff: third_party/WebKit/Source/web/RotationViewportAnchor.h

Issue 2184333002: Fix scroll anchoring during viewport resize. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add comment on m_drift Created 4 years, 5 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: third_party/WebKit/Source/web/RotationViewportAnchor.h
diff --git a/third_party/WebKit/Source/web/RotationViewportAnchor.h b/third_party/WebKit/Source/web/RotationViewportAnchor.h
index 6aa31308c7a4a728e073b27100d763e59803248b..f0ccb022241135ebf1ba73afa2fa0d95612117dc 100644
--- a/third_party/WebKit/Source/web/RotationViewportAnchor.h
+++ b/third_party/WebKit/Source/web/RotationViewportAnchor.h
@@ -10,7 +10,6 @@
#include "platform/geometry/IntRect.h"
#include "platform/geometry/LayoutRect.h"
#include "platform/heap/Handle.h"
-#include "web/ViewportAnchor.h"
namespace blink {
@@ -27,7 +26,7 @@ class VisualViewport;
// viewport origin maintains its orientation relative to the anchor. If there is
// no node or it is lost during the resize, we fall back to the resize anchor
// logic.
-class RotationViewportAnchor : public ViewportAnchor {
+class RotationViewportAnchor {
STACK_ALLOCATED();
public:
RotationViewportAnchor(FrameView& rootFrameView, VisualViewport&, const FloatSize& anchorInInnerViewCoords, PageScaleConstraintsSet&);
@@ -41,6 +40,9 @@ private:
void computeOrigins(const FloatSize& innerSize, IntPoint& mainFrameOffset, FloatPoint& visualViewportOffset) const;
+ Member<FrameView> m_rootFrameView;
+ Member<VisualViewport> m_visualViewport;
+
float m_oldPageScaleFactor;
float m_oldMinimumPageScaleFactor;
« no previous file with comments | « third_party/WebKit/Source/web/ResizeViewportAnchor.cpp ('k') | third_party/WebKit/Source/web/RotationViewportAnchor.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698