mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 759993. Part 0: FrameLayerBuilder::GetThebesLayerScaleForFrame should not cross popup boundaries. r=mattwoodrow
This commit is contained in:
parent
f2a74e894b
commit
15d3d80fbd
@ -3022,8 +3022,10 @@ PredictScaleForContent(nsIFrame* aFrame, nsIFrame* aAncestorWithScale,
|
||||
{
|
||||
gfx3DMatrix transform =
|
||||
gfx3DMatrix::ScalingMatrix(aScale.width, aScale.height, 1.0);
|
||||
if (aFrame != aAncestorWithScale) {
|
||||
// aTransform is applied first, then the scale is applied to the result
|
||||
transform = nsLayoutUtils::GetTransformToAncestor(aFrame, aAncestorWithScale)*transform;
|
||||
}
|
||||
gfxMatrix transform2d;
|
||||
if (transform.CanDraw2D(&transform2d)) {
|
||||
return transform2d.ScaleFactors(true);
|
||||
@ -3038,6 +3040,13 @@ FrameLayerBuilder::GetThebesLayerScaleForFrame(nsIFrame* aFrame)
|
||||
for (nsIFrame* f = aFrame; f; f = nsLayoutUtils::GetCrossDocParentFrame(f)) {
|
||||
last = f;
|
||||
|
||||
if (nsLayoutUtils::IsPopup(f)) {
|
||||
// Don't examine ancestors of a popup. It won't make sense to check
|
||||
// the transform from some content inside the popup to some content
|
||||
// which is an ancestor of the popup.
|
||||
break;
|
||||
}
|
||||
|
||||
nsTArray<DisplayItemData*> *array =
|
||||
reinterpret_cast<nsTArray<DisplayItemData*>*>(aFrame->Properties().Get(LayerManagerDataProperty()));
|
||||
if (!array) {
|
||||
|
Loading…
Reference in New Issue
Block a user