From 2a126872b065ef3181782ed0a7f972c4bd43ce06 Mon Sep 17 00:00:00 2001 From: "sharparrow1%yahoo.com" Date: Tue, 27 Feb 2007 22:05:16 +0000 Subject: [PATCH] Bug 371864: Background images don't load until scrolled into the viewport. r+sr=roc. --- layout/base/nsCSSFrameConstructor.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/layout/base/nsCSSFrameConstructor.cpp b/layout/base/nsCSSFrameConstructor.cpp index 386d7118767a..6360f837f2a8 100644 --- a/layout/base/nsCSSFrameConstructor.cpp +++ b/layout/base/nsCSSFrameConstructor.cpp @@ -7476,6 +7476,11 @@ nsCSSFrameConstructor::ConstructFrameInternal( nsFrameConstructorState& aState, { styleContext->GetStyleVisibility(); } + // Start background loads during frame construction. This is just + // a hint; the paint code will do the right thing in any case. + { + styleContext->GetStyleBackground(); + } nsIFrame* lastChild = frameItems->lastChild;