зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1846935
- Use FuzzyEqualsCoordinate in the computation of userScrolled. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D193393
This commit is contained in:
Родитель
06faa2fd8b
Коммит
4abbad51c7
|
@ -5314,10 +5314,11 @@ void AsyncPanZoomController::NotifyLayersUpdated(
|
|||
// XXX Suspicious comparison between layout and visual scroll offsets.
|
||||
// This may not do the right thing when we're zoomed in.
|
||||
CSSPoint lastScrollOffset = mLastContentPaintMetrics.GetLayoutScrollOffset();
|
||||
bool userScrolled = !FuzzyEqualsAdditive(Metrics().GetVisualScrollOffset().x,
|
||||
lastScrollOffset.x) ||
|
||||
!FuzzyEqualsAdditive(Metrics().GetVisualScrollOffset().y,
|
||||
lastScrollOffset.y);
|
||||
bool userScrolled =
|
||||
!FuzzyEqualsCoordinate(Metrics().GetVisualScrollOffset().x,
|
||||
lastScrollOffset.x) ||
|
||||
!FuzzyEqualsCoordinate(Metrics().GetVisualScrollOffset().y,
|
||||
lastScrollOffset.y);
|
||||
|
||||
if (aScrollMetadata.DidContentGetPainted()) {
|
||||
mLastContentPaintMetadata = aScrollMetadata;
|
||||
|
|
Загрузка…
Ссылка в новой задаче