mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 942995 - Squish the FrameMetrics::mScrollableRect for overflow:hidden elements. r=tn
This commit is contained in:
parent
2be311daa9
commit
811c422a69
@ -619,6 +619,12 @@ static void RecordFrameMetrics(nsIFrame* aForFrame,
|
||||
|
||||
if (scrollableFrame) {
|
||||
nsRect contentBounds = scrollableFrame->GetScrollRange();
|
||||
if (scrollableFrame->GetScrollbarStyles().mVertical == NS_STYLE_OVERFLOW_HIDDEN) {
|
||||
contentBounds.height = 0;
|
||||
}
|
||||
if (scrollableFrame->GetScrollbarStyles().mHorizontal == NS_STYLE_OVERFLOW_HIDDEN) {
|
||||
contentBounds.width = 0;
|
||||
}
|
||||
contentBounds.width += scrollableFrame->GetScrollPortRect().width;
|
||||
contentBounds.height += scrollableFrame->GetScrollPortRect().height;
|
||||
metrics.mScrollableRect = CSSRect::FromAppUnits(contentBounds);
|
||||
|
Loading…
Reference in New Issue
Block a user