Index: Source/web/ResizeViewportAnchor.cpp |
diff --git a/Source/web/ResizeViewportAnchor.cpp b/Source/web/ResizeViewportAnchor.cpp |
index 756bdc6605a4ed4324926085ef846086939e566d..41bd9c66a412374f2c446c3b2addc90b80b4a729 100644 |
--- a/Source/web/ResizeViewportAnchor.cpp |
+++ b/Source/web/ResizeViewportAnchor.cpp |
@@ -14,23 +14,20 @@ |
namespace blink { |
ResizeViewportAnchor::ResizeViewportAnchor(FrameView& rootFrameView, PinchViewport& pinchViewport) |
- : ViewportAnchor(rootFrameView, pinchViewport) { } |
- |
- |
-void ResizeViewportAnchor::setAnchor() |
+ : ViewportAnchor(rootFrameView, pinchViewport) |
+ , m_pinchViewportInDocument(m_pinchViewport->visibleRectInDocument().location()) |
{ |
- m_pinchViewportInDocument = m_pinchViewport.visibleRectInDocument().location(); |
} |
-void ResizeViewportAnchor::restoreToAnchor() |
+ResizeViewportAnchor::~ResizeViewportAnchor() |
{ |
- FloatSize delta = m_pinchViewportInDocument - m_pinchViewport.visibleRectInDocument().location(); |
+ FloatSize delta = m_pinchViewportInDocument - m_pinchViewport->visibleRectInDocument().location(); |
- DoublePoint targetFrameViewPosition = m_rootFrameView.scrollPositionDouble() + DoubleSize(delta); |
- m_rootFrameView.setScrollPosition(targetFrameViewPosition); |
+ DoublePoint targetFrameViewPosition = m_rootFrameView->scrollPositionDouble() + DoubleSize(delta); |
+ m_rootFrameView->setScrollPosition(targetFrameViewPosition); |
- DoubleSize remainder = targetFrameViewPosition - m_rootFrameView.scrollPositionDouble(); |
- m_pinchViewport.move(toFloatSize(remainder)); |
+ DoubleSize remainder = targetFrameViewPosition - m_rootFrameView->scrollPositionDouble(); |
+ m_pinchViewport->move(toFloatSize(remainder)); |
} |
} // namespace blink |