Bug 1514679 - Move vScrollbarActualWidth inside the if block where the value is used. r=botond

Depends on D14714

Differential Revision: https://phabricator.services.mozilla.com/D14715

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Hiroyuki Ikezoe 2018-12-17 21:54:24 +00:00
Родитель 0a0f595df0
Коммит d864a9f8f1
1 изменённых файлов: 2 добавлений и 3 удалений

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

@ -443,14 +443,13 @@ bool nsHTMLScrollFrame::TryLayout(ScrollReflowInput* aState,
doc->UpdateViewportOverflowType(scrolledWidth, scrollPortSize.width);
} while (false);
nscoord vScrollbarActualWidth =
aState->mInsideBorderSize.width - scrollPortSize.width;
aState->mShowHScrollbar = aAssumeHScroll;
aState->mShowVScrollbar = aAssumeVScroll;
nsPoint scrollPortOrigin(aState->mComputedBorder.left,
aState->mComputedBorder.top);
if (!IsScrollbarOnRight()) {
nscoord vScrollbarActualWidth =
aState->mInsideBorderSize.width - scrollPortSize.width;
scrollPortOrigin.x += vScrollbarActualWidth;
}
mHelper.mScrollPort = nsRect(scrollPortOrigin, scrollPortSize);