Bug 1732600. Make GetDisplayPortFromMarginsData use ancestor process transform to ancestor scale. r=botond

Differential Revision: https://phabricator.services.mozilla.com/D126661
This commit is contained in:
Timothy Nikkel 2021-10-05 09:28:58 +00:00
Родитель 44555d25b7
Коммит 4fdbd2ef36
1 изменённых файлов: 5 добавлений и 3 удалений

Просмотреть файл

@ -295,9 +295,11 @@ static nsRect GetDisplayPortFromMarginsData(
nsPresContext* presContext = frame->PresContext();
int32_t auPerDevPixel = presContext->AppUnitsPerDevPixel();
LayoutDeviceToScreenScale2D res(
presContext->PresShell()->GetCumulativeResolution() *
nsLayoutUtils::GetTransformToAncestorScale(frame));
LayoutDeviceToScreenScale2D res =
LayoutDeviceToParentLayerScale(
presContext->PresShell()->GetCumulativeResolution()) *
nsLayoutUtils::GetTransformToAncestorScaleCrossProcessForFrameMetrics(
frame);
// Calculate the expanded scrollable rect, which we'll be clamping the
// displayport to.