зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1319560 Part 3: Change nsDisplayList::HitTest to exit early when HitTestShouldStopAtFirstOpaque() is true. r=mattwoodrow
MozReview-Commit-ID: D8aKGX6z2TV --HG-- extra : rebase_source : 8a698f3ab58cd571c58d346e8ad2fcc3b0eef4c7
This commit is contained in:
Родитель
e138a742a2
Коммит
bffacaf61c
|
@ -2218,6 +2218,13 @@ void nsDisplayList::HitTest(nsDisplayListBuilder* aBuilder, const nsRect& aRect,
|
|||
writeFrames->AppendElement(f);
|
||||
}
|
||||
}
|
||||
|
||||
if (aBuilder->HitTestShouldStopAtFirstOpaque() &&
|
||||
item->GetOpaqueRegion(aBuilder, &snap).Contains(aRect)) {
|
||||
// We're exiting early, so pop the remaining items off the buffer.
|
||||
aState->mItemBuffer.SetLength(itemBufferStart);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
// Clear any remaining preserve-3d transforms.
|
||||
|
|
Загрузка…
Ссылка в новой задаче