Bug 1284553 - Use a fuzzy-compare for the presShell resolution so that negligible differences don't block all repaint requests. r?botond
MozReview-Commit-ID: EhyhYYLgssQ
--- a/gfx/layers/apz/util/APZCCallbackHelper.cpp
+++ b/gfx/layers/apz/util/APZCCallbackHelper.cpp
@@ -244,17 +244,17 @@ APZCCallbackHelper::UpdateRootFrame(Fram
// to be returned by window.innerWidth/innerHeight (see bug 1187792).
float presShellResolution = shell->GetResolution();
// If the pres shell resolution has changed on the content side side
// the time this repaint request was fired, consider this request out of date
// and drop it; setting a zoom based on the out-of-date resolution can have
// the effect of getting us stuck with the stale resolution.
- if (presShellResolution != aMetrics.GetPresShellResolution()) {
+ if (!FuzzyEqualsMultiplicative(presShellResolution, aMetrics.GetPresShellResolution())) {
return;
}
// The pres shell resolution is updated by the the async zoom since the
// last paint.
presShellResolution = aMetrics.GetPresShellResolution()
* aMetrics.GetAsyncZoom().scale;
shell->SetResolutionAndScaleTo(presShellResolution);