summaryrefslogtreecommitdiffstats
path: root/Source/WebCore/platform/graphics/android/GLWebViewState.cpp
diff options
context:
space:
mode:
authorChris Craik <ccraik@google.com>2011-08-23 13:36:18 -0700
committerChris Craik <ccraik@google.com>2011-08-25 15:08:33 -0700
commitf51a51f6ea307f4311a04aa865a42b233269540b (patch)
tree62856bffa8b6e82f229a76cc324b28c4286496ee /Source/WebCore/platform/graphics/android/GLWebViewState.cpp
parent5a1bad665e3c27495e4ccb9a73996ce3a84b0a26 (diff)
downloadexternal_webkit-f51a51f6ea307f4311a04aa865a42b233269540b.zip
external_webkit-f51a51f6ea307f4311a04aa865a42b233269540b.tar.gz
external_webkit-f51a51f6ea307f4311a04aa865a42b233269540b.tar.bz2
better locking while scrolling, but disables double buffering
don't detect scrolling, query from java removes double buffering depends on CL in frameworks/base: https://android-git.corp.google.com/g/#/c/130213/ bug:5106313 Change-Id: Ibfa7f305874f4209fed001c030bb94e752d479b9
Diffstat (limited to 'Source/WebCore/platform/graphics/android/GLWebViewState.cpp')
-rw-r--r--Source/WebCore/platform/graphics/android/GLWebViewState.cpp14
1 files changed, 6 insertions, 8 deletions
diff --git a/Source/WebCore/platform/graphics/android/GLWebViewState.cpp b/Source/WebCore/platform/graphics/android/GLWebViewState.cpp
index 3cc192f..e07c86f 100644
--- a/Source/WebCore/platform/graphics/android/GLWebViewState.cpp
+++ b/Source/WebCore/platform/graphics/android/GLWebViewState.cpp
@@ -64,7 +64,8 @@ namespace WebCore {
using namespace android;
GLWebViewState::GLWebViewState(android::Mutex* buttonMutex)
- : m_baseLayer(0)
+ : m_zoomManager(this)
+ , m_baseLayer(0)
, m_currentBaseLayer(0)
, m_previouslyUsedRoot(0)
, m_currentPictureCounter(0)
@@ -76,14 +77,13 @@ GLWebViewState::GLWebViewState(android::Mutex* buttonMutex)
, m_backgroundColor(SK_ColorWHITE)
, m_displayRings(false)
, m_focusRingTexture(-1)
+ , m_isScrolling(false)
, m_goingDown(true)
, m_goingLeft(false)
, m_expandedTileBoundsX(0)
, m_expandedTileBoundsY(0)
- , m_zoomManager(this)
{
m_viewport.setEmpty();
- m_previousViewport.setEmpty();
m_futureViewportTileBounds.setEmpty();
m_viewportTileBounds.setEmpty();
m_preZoomBounds.setEmpty();
@@ -226,8 +226,7 @@ void GLWebViewState::inval(const IntRect& rect)
m_currentPictureCounter++;
if (!rect.isEmpty()) {
// find which tiles fall within the invalRect and mark them as dirty
- m_tiledPageA->invalidateRect(rect, m_currentPictureCounter);
- m_tiledPageB->invalidateRect(rect, m_currentPictureCounter);
+ frontPage()->invalidateRect(rect, m_currentPictureCounter);
if (m_frameworkInval.isEmpty())
m_frameworkInval = rect;
else
@@ -372,13 +371,12 @@ int GLWebViewState::baseContentHeight()
void GLWebViewState::setViewport(SkRect& viewport, float scale)
{
- m_previousViewport = m_viewport;
if ((m_viewport == viewport) &&
(zoomManager()->futureScale() == scale))
return;
- m_goingDown = m_previousViewport.fTop - viewport.fTop <= 0;
- m_goingLeft = m_previousViewport.fLeft - viewport.fLeft >= 0;
+ m_goingDown = m_viewport.fTop - viewport.fTop <= 0;
+ m_goingLeft = m_viewport.fLeft - viewport.fLeft >= 0;
m_viewport = viewport;
XLOG("New VIEWPORT %.2f - %.2f %.2f - %.2f (w: %2.f h: %.2f scale: %.2f currentScale: %.2f futureScale: %.2f)",