зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1198135 - Part 3: Set the size of HTMLScrollFrames earlier so that we compute perspective earlier. r=dbaron
This commit is contained in:
Родитель
154d6e080e
Коммит
3025106c4e
|
@ -1034,6 +1034,16 @@ nsHTMLScrollFrame::Reflow(nsPresContext* aPresContext,
|
|||
|
||||
ReflowContents(&state, aDesiredSize);
|
||||
|
||||
aDesiredSize.Width() = state.mInsideBorderSize.width +
|
||||
state.mComputedBorder.LeftRight();
|
||||
aDesiredSize.Height() = state.mInsideBorderSize.height +
|
||||
state.mComputedBorder.TopBottom();
|
||||
|
||||
// Set the size of the frame now since computing the perspective-correct
|
||||
// overflow (within PlaceScrollArea) can rely on it.
|
||||
SetSize(aDesiredSize.GetWritingMode(),
|
||||
aDesiredSize.Size(aDesiredSize.GetWritingMode()));
|
||||
|
||||
// Restore the old scroll position, for now, even if that's not valid anymore
|
||||
// because we changed size. We'll fix it up in a post-reflow callback, because
|
||||
// our current size may only be temporary (e.g. we're compute XUL desired sizes).
|
||||
|
@ -1073,11 +1083,6 @@ nsHTMLScrollFrame::Reflow(nsPresContext* aPresContext,
|
|||
}
|
||||
}
|
||||
|
||||
aDesiredSize.Width() = state.mInsideBorderSize.width +
|
||||
state.mComputedBorder.LeftRight();
|
||||
aDesiredSize.Height() = state.mInsideBorderSize.height +
|
||||
state.mComputedBorder.TopBottom();
|
||||
|
||||
aDesiredSize.SetOverflowAreasToDesiredBounds();
|
||||
if (mHelper.IsIgnoringViewportClipping()) {
|
||||
aDesiredSize.mOverflowAreas.UnionWith(
|
||||
|
|
Загрузка…
Ссылка в новой задаче