Bug 1701928 - Selection scrolling should not ignore scroll-{margin,padding}. r=hiro,masayuki
Differential Revision: https://phabricator.services.mozilla.com/D110440
This commit is contained in:
@@ -1810,7 +1810,7 @@ nsresult AutoScroller::DoAutoScroll(nsIFrame* aFrame, nsPoint aPoint) {
|
||||
while (true) {
|
||||
didScroll = presShell->ScrollFrameRectIntoView(
|
||||
aFrame, nsRect(aPoint, nsSize(0, 0)), ScrollAxis(), ScrollAxis(),
|
||||
ScrollFlags::IgnoreMarginAndPadding);
|
||||
ScrollFlags::None);
|
||||
if (!weakFrame || !weakRootFrame) {
|
||||
return NS_OK;
|
||||
}
|
||||
@@ -2996,7 +2996,7 @@ nsresult Selection::ScrollIntoView(SelectionRegion aRegion,
|
||||
// vertical scrollbar or the scroll range is at least one device pixel)
|
||||
aVertical.mOnlyIfPerceivedScrollableDirection = true;
|
||||
|
||||
ScrollFlags scrollFlags = ScrollFlags::IgnoreMarginAndPadding;
|
||||
auto scrollFlags = ScrollFlags::None;
|
||||
if (aFlags & Selection::SCROLL_FIRST_ANCESTOR_ONLY) {
|
||||
scrollFlags |= ScrollFlags::ScrollFirstAncestorOnly;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user