Bug 1041530. Be more careful about contributing opaque areas to the window region. r=mattwoodrow

--HG--
extra : rebase_source : 3665198c22b44644a876332a5b6e8a480c64a3f5
This commit is contained in:
Robert O'Callahan 2014-07-22 23:14:40 +12:00
parent 631b440c3f
commit cf610d84fa

View File

@ -2635,10 +2635,11 @@ ContainerState::ComputeOpaqueRect(nsDisplayItem* aItem,
opaqueClipped.Contains(mContainerBounds)) {
aList->SetIsOpaque();
}
// Add opaque areas to the "exclude glass" region. Only do this for
// ThebesLayers which are direct children of the root layer; this means
// they can't have transforms or opacity wrapping them.
if (!mContainerLayer->GetParent()) {
// Add opaque areas to the "exclude glass" region. Only do this when our
// container layer is going to be the rootmost layer, otherwise transforms
// etc will mess us up (and opaque contributions from other containers are
// not needed).
if (!nsLayoutUtils::GetCrossDocParentFrame(mContainerFrame)) {
mBuilder->AddWindowOpaqueRegion(opaqueClipped);
}
opaquePixels = ScaleRegionToInsidePixels(opaqueClipped, snapOpaque);