mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 750293 - Don't include a block's margins in its scrollable overflow for now. r=roc
This commit is contained in:
parent
2069530602
commit
e5191a317a
@ -6771,26 +6771,6 @@ nsIFrame::FinishAndStoreOverflow(nsOverflowAreas& aOverflowAreas,
|
||||
nsRect& o = aOverflowAreas.Overflow(otype);
|
||||
o.UnionRectEdges(o, bounds);
|
||||
}
|
||||
|
||||
if (!nsLayoutUtils::IsPopup(this)) {
|
||||
// Include margin in scrollable overflow.
|
||||
// XXX In theory this should consider margin collapsing
|
||||
nsRect marginBounds(bounds);
|
||||
nsMargin margin = GetUsedMargin();
|
||||
|
||||
// Bug 724352 - vertical scrollable overflow only matters for
|
||||
// scroll frames which are block margin roots and has already
|
||||
// accumulated child vertical margins during reflow. We need
|
||||
// to revisit this when using UpdateOverflow for non-transform
|
||||
// style changes (bug 719177).
|
||||
margin.top = 0;
|
||||
margin.bottom = 0;
|
||||
|
||||
ApplySkipSides(margin);
|
||||
marginBounds.SaturatingInflate(margin);
|
||||
nsRect& so = aOverflowAreas.ScrollableOverflow();
|
||||
so.SaturatingUnionRectEdges(so, marginBounds);
|
||||
}
|
||||
}
|
||||
|
||||
// Note that NS_STYLE_OVERFLOW_CLIP doesn't clip the frame background,
|
||||
|
@ -11,14 +11,14 @@
|
||||
x1,x2,x3,x4,x5,x6 { display:block; }
|
||||
x2 { overflow:auto; width:100px; background:grey; }
|
||||
x4 { width: 70px; }
|
||||
x3 { width: 70px; padding: 0 20px; }
|
||||
x3 { width: 70px; padding-left: 20px; padding-right: 10px; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<x1><x2 style="height:50px;">
|
||||
<x3><x4 style="height:20px; background:lime; "></x4></x3>
|
||||
</x2>
|
||||
</x2></x1>
|
||||
|
||||
|
||||
</body>
|
||||
|
@ -17,7 +17,7 @@ x4 { width: 70px; margin: 0 20px; }
|
||||
|
||||
<x1><x2 style="height:50px;">
|
||||
<x4 style="height:20px; background:lime; "></x4>
|
||||
</x2>
|
||||
</x2></x1>
|
||||
|
||||
|
||||
</body>
|
||||
|
Loading…
Reference in New Issue
Block a user