diff --git a/layout/base/tests/Makefile.in b/layout/base/tests/Makefile.in index 97021ffec0a..c4f899af8c5 100644 --- a/layout/base/tests/Makefile.in +++ b/layout/base/tests/Makefile.in @@ -65,8 +65,6 @@ _TEST_FILES = \ bug369950-subframe.xml \ bug495648.rdf \ decoration_line_rendering.js \ - region_lib.js \ - scrolling_helper.html \ test_bug66619.html \ test_bug114649.html \ $(warning test_bug369950.html disabled due to random orange; see bug 492575) \ @@ -108,7 +106,6 @@ _TEST_FILES = \ test_flush_on_paint.html \ test_mozPaintCount.html \ test_scroll_selection_into_view.html \ - test_scrolling.html \ $(NULL) # Tests for bugs 441782, 467672 and 570378 don't pass reliably on Windows, because of bug 469208 diff --git a/layout/base/tests/region_lib.js b/layout/base/tests/region_lib.js deleted file mode 100644 index 2bb92612a57..00000000000 --- a/layout/base/tests/region_lib.js +++ /dev/null @@ -1,111 +0,0 @@ -/* - * JS region library. This deals in rectangles which are arrays of 4 elements: - * left, top, right, bottom. - * - * The constructor constructs a region from a list of rects. If no list is - * passed, then we return an empty region. - */ -function Region(rects) { - this._rects = rects || []; -} - -(function() { -function dumpRect(r) { - return "{" + r.join(",") + "}"; -} - -function generateSpan(coords) { - coords.sort(function(a,b) { return a - b; }); - var result = [coords[0]]; - for (var i = 1; i < coords.length; ++i) { - if (coords[i] != coords[i - 1]) { - result.push(coords[i]); - } - } - return result; -} - -function rectContainsRect(r1, r2) { - return r1[0] <= r2[0] && r1[2] >= r2[2] && - r1[1] <= r2[1] && r1[3] >= r2[3]; -} - -function rectIntersectsRect(r1, r2) { - return Math.max(r1[0], r2[0]) < Math.min(r1[2], r2[2]) && - Math.max(r1[1], r2[1]) < Math.min(r1[3], r2[3]); -} - -function subtractRect(r1, r2, rlist) { - var spanX = generateSpan([r1[0], r1[2], r2[0], r2[2]]); - var spanY = generateSpan([r1[1], r1[3], r2[1], r2[3]]); - for (var i = 1; i < spanX.length; ++i) { - for (var j = 1; j < spanY.length; ++j) { - var subrect = [spanX[i - 1], spanY[j - 1], spanX[i], spanY[j]]; - if (rectContainsRect(r1, subrect) && !rectContainsRect(r2, subrect)) { - rlist.push(subrect); - } - } - } -} - -// Return the contents of the region as a string -Region.prototype.toString = function Region_toString() { - var s = []; - for (var i = 0; i < this._rects.length; ++i) { - var r = this._rects[i]; - s.push(dumpRect(r)); - } - return "Region(" + s.join(",") + ")"; -}; - -// Returns true if the region contains the entire rectangle r -Region.prototype.containsRect = function Region_containsRect(r) { - var rectList = [r]; - for (var i = 0; i < this._rects.length; ++i) { - var newList = []; - for (var j = 0; j < rectList.length; ++j) { - subtractRect(rectList[j], this._rects[i], newList); - } - if (newList.length == 0) - return true; - rectList = newList; - } - return false; -}; - -Region.prototype.isEmpty = function Region_isEmpty() { - for (var i = 0; i < this._rects.length; ++i) { - var r = this._rects[i]; - if (r[0] < r[2] && r[1] < r[3]) - return false; - } - return true; -}; - -Region.prototype.intersectsRect = function Region_intersectsRect(r) { - for (var i = 0; i < this._rects.length; ++i) { - if (rectIntersectsRect(this._rects[i], r)) - return true; - } - return false; -}; - -// Returns true if the region contains the entire region rgn -Region.prototype.containsRegion = function Region_containsRegion(rgn) { - for (var i = 0; i < rgn._rects.length; ++i) { - if (!this.containsRect(rgn._rects[i])) - return false; - } - return true; -}; - -// Return a region which is the union of this region and another region -Region.prototype.unionRegion = function Region_unionRegion(rgn) { - return new Region(this._rects.concat(rgn._rects)); -}; - -// Returns true if the region covers exactly the same area as region rgn -Region.prototype.equalsRegion = function Region_equalsRegion(rgn) { - return this.containsRegion(rgn) && rgn.containsRegion(this); -}; -})(); diff --git a/layout/base/tests/scrolling_helper.html b/layout/base/tests/scrolling_helper.html deleted file mode 100644 index a77bbf0da36..00000000000 --- a/layout/base/tests/scrolling_helper.html +++ /dev/null @@ -1,454 +0,0 @@ - - -
- - - - - - - - -Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
Hello -
- -- - diff --git a/layout/reftests/bugs/379349-3a.xhtml b/layout/reftests/bugs/379349-3a.xhtml index a6e430eaa8c..3b6c479cc32 100644 --- a/layout/reftests/bugs/379349-3a.xhtml +++ b/layout/reftests/bugs/379349-3a.xhtml @@ -33,6 +33,9 @@ height: 24.33333in; border-bottom-color: blue; } + .fill { + height: 75in; + } @@ -54,5 +57,7 @@ on a page after the first (assuming the page area is shorter than 25 inches). +