diff options
author | Teng-Hui Zhu <ztenghui@google.com> | 2012-04-02 09:47:14 -0700 |
---|---|---|
committer | Teng-Hui Zhu <ztenghui@google.com> | 2012-04-02 16:23:43 -0700 |
commit | afe34397d6d4655c908f0995e760772980722da3 (patch) | |
tree | 5a1380e2d581391c33713c793b06cd577ca09da6 /Source/WebCore/platform/graphics/android/GLWebViewState.cpp | |
parent | de5a3eeb42d8930d4fd09d86953de929c450f7a6 (diff) | |
download | external_webkit-afe34397d6d4655c908f0995e760772980722da3.zip external_webkit-afe34397d6d4655c908f0995e760772980722da3.tar.gz external_webkit-afe34397d6d4655c908f0995e760772980722da3.tar.bz2 |
Translucent background color support for webview
We need to respect the background color set for webview and combine that with
the CSS background.
Since we are tiled based and need to avoid double drawing, we need to determine
the areas not covered by available tiles and draw the background. This involves
a bit computation overhead. Therefore, we only compute those areas when alpha
is between 1 to 254.
When alpha is 255, we just need a glClear. When alpha is 0, nothing need to be
drawn.
Due to the fact that the tile can be partially drawn, texture generator need to
know the background color to clear the tiles for the base layer.
bug:5684832
Change-Id: I51f9d219f2722cc088eeea603623f9660f7a136a
Diffstat (limited to 'Source/WebCore/platform/graphics/android/GLWebViewState.cpp')
-rw-r--r-- | Source/WebCore/platform/graphics/android/GLWebViewState.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/Source/WebCore/platform/graphics/android/GLWebViewState.cpp b/Source/WebCore/platform/graphics/android/GLWebViewState.cpp index b7458e8..a5080ca 100644 --- a/Source/WebCore/platform/graphics/android/GLWebViewState.cpp +++ b/Source/WebCore/platform/graphics/android/GLWebViewState.cpp @@ -156,10 +156,9 @@ void GLWebViewState::setViewport(const SkRect& viewport, float scale) m_isViewportScrolling = m_viewport != viewport && SkRect::Intersects(m_viewport, viewport); m_viewport = viewport; - ALOGV("New VIEWPORT %.2f - %.2f %.2f - %.2f (w: %2.f h: %.2f scale: %.2f currentScale: %.2f futureScale: %.2f)", + ALOGV("New VIEWPORT %.2f - %.2f %.2f - %.2f (w: %2.f h: %.2f scale: %.2f )", m_viewport.fLeft, m_viewport.fTop, m_viewport.fRight, m_viewport.fBottom, - m_viewport.width(), m_viewport.height(), scale, - zoomManager()->currentScale(), zoomManager()->futureScale()); + m_viewport.width(), m_viewport.height(), scale); } #ifdef MEASURES_PERF |