summaryrefslogtreecommitdiffstats
path: root/WebCore/platform/graphics/android/GLWebViewState.cpp
diff options
context:
space:
mode:
authorNicolas Roard <nicolas@android.com>2010-11-22 19:48:11 -0800
committerNicolas Roard <nicolas@android.com>2010-11-24 13:42:16 -0800
commit7a661f000fc142aec9e4f88b04d0a0ee20a0151e (patch)
treebebb79f89eea3e9dc9f2ad974f5b1fcf89db40dd /WebCore/platform/graphics/android/GLWebViewState.cpp
parenteabb311cd2b57ff80b4cf632078cf078d789b563 (diff)
downloadexternal_webkit-7a661f000fc142aec9e4f88b04d0a0ee20a0151e.zip
external_webkit-7a661f000fc142aec9e4f88b04d0a0ee20a0151e.tar.gz
external_webkit-7a661f000fc142aec9e4f88b04d0a0ee20a0151e.tar.bz2
Refactoring the zoom
Change-Id: I84d44b6aab2222b52d21a65ceb74e390c677fe72
Diffstat (limited to 'WebCore/platform/graphics/android/GLWebViewState.cpp')
-rw-r--r--WebCore/platform/graphics/android/GLWebViewState.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/WebCore/platform/graphics/android/GLWebViewState.cpp b/WebCore/platform/graphics/android/GLWebViewState.cpp
index 145bd89..fbf33c2 100644
--- a/WebCore/platform/graphics/android/GLWebViewState.cpp
+++ b/WebCore/platform/graphics/android/GLWebViewState.cpp
@@ -74,6 +74,7 @@ GLWebViewState::GLWebViewState()
, m_usePageA(true)
{
m_viewport.setEmpty();
+ m_futureViewportTileBounds.setEmpty();
m_viewportTileBounds.setEmpty();
m_preZoomBounds.setEmpty();
@@ -133,13 +134,15 @@ unsigned int GLWebViewState::paintBaseLayerContent(SkCanvas* canvas)
return m_currentPictureCounter;
}
-void GLWebViewState::scheduleUpdate(const double& currentTime, float scale)
+void GLWebViewState::scheduleUpdate(const double& currentTime,
+ const SkIRect& viewport, float scale)
{
// if no update time, set it
if (updateTime() == -1) {
m_scaleRequestState = kWillScheduleRequest;
setUpdateTime(currentTime + s_updateInitialDelay);
setFutureScale(scale);
+ setFutureViewport(viewport);
return;
}
@@ -158,6 +161,7 @@ void GLWebViewState::scheduleUpdate(const double& currentTime, float scale)
// in the process of zooming. Let's push the update time a bit.
setUpdateTime(currentTime + s_updateDelay);
setFutureScale(scale);
+ setFutureViewport(viewport);
}
}