Bug 1172270 - backed out changeset b38b8126e4d1 (bug 1160775), a=backout/relman
authorGijs Kruitbosch <gijskruitbosch@gmail.com>
Mon, 08 Jun 2015 15:56:51 +0100
changeset 273463 1ce864d841dbb211c74f7a95fb9b332d708a8d61
parent 273462 77aebefaa4de1f71d9085cd5c7fcee0ccfc546c4
child 273464 e566a3e330a7d9b8a1aef41862bdeb40ae493e37
push id4830
push userjlund@mozilla.com
push dateMon, 29 Jun 2015 20:18:48 +0000
treeherdermozilla-beta@4c2175bb0420 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbackout, relman
bugs1172270, 1160775
milestone40.0a2
Bug 1172270 - backed out changeset b38b8126e4d1 (bug 1160775), a=backout/relman
toolkit/components/reader/ReaderMode.jsm
--- a/toolkit/components/reader/ReaderMode.jsm
+++ b/toolkit/components/reader/ReaderMode.jsm
@@ -127,30 +127,22 @@ this.ReaderMode = {
     if (!this._shouldCheckUri(uri)) {
       return false;
     }
 
     let utils = this.getUtilsForWin(doc.defaultView);
     // We pass in a helper function to determine if a node is visible, because
     // it uses gecko APIs that the engine-agnostic readability code can't rely
     // upon.
-    // NB: we need to do a flush the first time we call this, so we keep track of
-    // this using a property:
-    this._needFlushForVisibilityCheck = true;
-    return new Readability(uri, doc).isProbablyReaderable(this.isNodeVisible.bind(this, utils));
+    // NOTE: This is currently disabled, see bug 1158228.
+    return new Readability(uri, doc).isProbablyReaderable(/*this.isNodeVisible.bind(this, utils)*/);
   },
 
   isNodeVisible: function(utils, node) {
-    let bounds;
-    if (this._needFlushForVisibilityCheck) {
-      bounds = node.getBoundingClientRect();
-      this._needFlushForVisibilityCheck = false;
-    } else {
-      bounds = utils.getBoundsWithoutFlushing(node);
-    }
+    let bounds = utils.getBoundsWithoutFlushing(node);
     return bounds.height > 0 && bounds.width > 0;
   },
 
   getUtilsForWin: function(win) {
     return win.QueryInterface(Ci.nsIInterfaceRequestor).getInterface(Ci.nsIDOMWindowUtils);
   },
 
   /**