diff options
| author | 2011-12-05 15:19:00 -0800 | |
|---|---|---|
| committer | 2011-12-05 16:56:16 -0800 | |
| commit | 5d3f6e6d25f98af2dd158bac8da7516bd976a8a5 (patch) | |
| tree | 13c3c61a316d9286f07b7eacf6f16abb6648e0cf | |
| parent | fe0d3523a52d7f05d54cbf917670d808e0765bb2 (diff) | |
Remove inFullScreenMode JNI call during drawGL call.
Bug 5629367
Corresponding WebKit change: Ia6f11636
Change-Id: Icc2fb6b778ce1c9bb4dc216a558652de544028b1
| -rw-r--r-- | core/java/android/webkit/WebView.java | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/core/java/android/webkit/WebView.java b/core/java/android/webkit/WebView.java index 4958d3cbc9f4..b68dec9905d8 100644 --- a/core/java/android/webkit/WebView.java +++ b/core/java/android/webkit/WebView.java @@ -4250,6 +4250,9 @@ public class WebView extends AbsoluteLayout @Override protected void onDraw(Canvas canvas) { + if (inFullScreenMode()) { + return; // no need to draw anything if we aren't visible. + } // if mNativeClass is 0, the WebView is either destroyed or not // initialized. In either case, just draw the background color and return if (mNativeClass == 0) { @@ -5833,7 +5836,8 @@ public class WebView extends AbsoluteLayout } calcOurContentVisibleRectF(mVisibleContentRect); nativeUpdateDrawGLFunction(mGLViewportEmpty ? null : mGLRectViewport, - mGLViewportEmpty ? null : mViewRectViewport, mVisibleContentRect); + mGLViewportEmpty ? null : mViewRectViewport, + mVisibleContentRect); } /** @@ -5980,6 +5984,7 @@ public class WebView extends AbsoluteLayout if (inFullScreenMode()) { mFullScreenHolder.hide(); mFullScreenHolder = null; + invalidate(); } } @@ -8655,6 +8660,7 @@ public class WebView extends AbsoluteLayout mFullScreenHolder = new PluginFullScreenHolder(WebView.this, orientation, npp); mFullScreenHolder.setContentView(view); mFullScreenHolder.show(); + invalidate(); break; } |