Bug 814864 - Abort old, stale, low precision updates. r=kats
authorChris Lord <chrislord.net@gmail.com>
Thu, 29 Nov 2012 13:08:40 +0000
changeset 123583 a281a71fc4e6ae51a318545c0148f9ea5404e219
parent 123582 13ee7ebc101a00c4b9b7a7f9abeff8bf972a3061
child 123584 8df524ad81939550730b6bec200254c1b27eaa01
push id2151
push userlsblakk@mozilla.com
push dateTue, 19 Feb 2013 18:06:57 +0000
treeherdermozilla-beta@4952e88741ec [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskats
bugs814864
milestone20.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 814864 - Abort old, stale, low precision updates. r=kats Don't spend time during stale, low precision content when there are newer display ports in the pipeline.
mobile/android/base/gfx/GeckoLayerClient.java
--- a/mobile/android/base/gfx/GeckoLayerClient.java
+++ b/mobile/android/base/gfx/GeckoLayerClient.java
@@ -407,16 +407,21 @@ public class GeckoLayerClient
             Math.max(viewportMetrics.viewportRectTop, viewportMetrics.pageRectTop) + 1 < y ||
             Math.min(viewportMetrics.viewportRectRight, viewportMetrics.pageRectRight) - 1 > x + width ||
             Math.min(viewportMetrics.viewportRectBottom, viewportMetrics.pageRectBottom) - 1 > y + height) {
             Log.d(LOGTAG, "Aborting update due to viewport not in display-port");
             mProgressiveUpdateData.abort = true;
             return mProgressiveUpdateData;
         }
 
+        // Abort drawing stale low-precision content if there's a more recent
+        // display-port in the pipeline.
+        if (lowPrecision && !aHasPendingNewThebesContent) {
+          mProgressiveUpdateData.abort = true;
+        }
         return mProgressiveUpdateData;
     }
 
     /** Implementation of GeckoEventResponder/GeckoEventListener. */
     public void handleMessage(String event, JSONObject message) {
         try {
             if ("Checkerboard:Toggle".equals(event)) {
                 mView.setCheckerboardShouldShowChecks(message.getBoolean("value"));