Bug 795940 - Part 0.4 - Only try to downscale images that have a single instance on a web page, since that's all we support anyhow. r=jrmuizel

--HG--
extra : rebase_source : 1bda15c8edb7e2d1d3ca26354ce8429640b03b43
This commit is contained in:
Joe Drew 2012-10-12 18:20:25 -04:00
parent 573a5425f8
commit 38c28c41f2

View File

@ -2792,8 +2792,10 @@ RasterImage::DrawWithPreDownscaleIfNeeded(imgFrame *aFrame,
subimage.ScaleRoundOut(scale.width, scale.height);
}
// If we're not waiting for exactly this result, ask for it.
else if (!(mScaleResult.status == SCALE_PENDING && mScaleResult.scale == scale)) {
// If we're not waiting for exactly this result, and there's only one
// instance of this image on this page, ask for a scale.
else if (!(mScaleResult.status == SCALE_PENDING && mScaleResult.scale == scale) &&
mLockCount == 1) {
// If we have an oustanding request, signal it to stop (if it can).
if (mScaleRequest) {
mScaleRequest->stopped = true;