Closed Bug 749164 Opened 12 years ago Closed 12 years ago

tcheckerboard2 sometimes returns NaNs

Categories

(Firefox for Android Graveyard :: General, defect)

All
Android
defect
Not set
normal

Tracking

(firefox15 fixed)

RESOLVED FIXED
Firefox 15
Tracking Status
firefox15 --- fixed

People

(Reporter: kats, Assigned: kats)

References

Details

Attachments

(1 file)

The patch for bug 748382 seems to have made it possible for the checkerboard tests to return NaN because the screenArea calculated might be zero.
Attached patch Proposed patchSplinter Review
Running this through try right now. The problem was that mPageRect is already translated by the viewport origin, so when you scroll to the bottom of a page like CNN you'd get something like viewport at 0,1281,720,2319 and page at 0,-1281,720,877 which would then intersect to empty.

Also normally you should never be able to get into a case where the intersection is empty, but I added an extra check to guard against it anyway.
Attachment #618646 - Flags: review?(jmuizelaar)
Comment on attachment 618646 [details] [diff] [review]
Proposed patch

viewport is a bad name for this variable.
Attachment #618646 - Flags: review?(jmuizelaar) → review+
https://hg.mozilla.org/mozilla-central/rev/ead719dd0ec1
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: