mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 05:11:16 +00:00
Bug 907495 - Scrollbars cause content to be shifted in e10s (r=kats,mattwoodrow)
This commit is contained in:
parent
13f6ac3ccb
commit
dfc3ae2fef
@ -678,6 +678,16 @@ static void RecordFrameMetrics(nsIFrame* aForFrame,
|
||||
mozilla::gfx::IntRect(bounds.x, bounds.y, bounds.width, bounds.height));
|
||||
}
|
||||
|
||||
// Adjust for the size of scroll bars.
|
||||
if (scrollableFrame) {
|
||||
nsMargin sizes = scrollableFrame->GetActualScrollbarSizes();
|
||||
ScreenIntMargin boundMargins(nsPresContext::AppUnitsToIntCSSPixels(sizes.top),
|
||||
nsPresContext::AppUnitsToIntCSSPixels(sizes.right),
|
||||
nsPresContext::AppUnitsToIntCSSPixels(sizes.bottom),
|
||||
nsPresContext::AppUnitsToIntCSSPixels(sizes.left));
|
||||
metrics.mCompositionBounds.Deflate(boundMargins);
|
||||
}
|
||||
|
||||
metrics.mPresShellId = presShell->GetPresShellId();
|
||||
|
||||
aRoot->SetFrameMetrics(metrics);
|
||||
|
Loading…
Reference in New Issue
Block a user