зеркало из https://github.com/mozilla/gecko-dev.git
Bug 827836 - Force sending a viewport update to Gecko after aborting animations. r=Cwiiis
This commit is contained in:
Родитель
995421a97b
Коммит
2bb89fead7
|
@ -477,9 +477,9 @@ public class GeckoLayerClient implements LayerView.Listener, PanZoomTarget
|
|||
// At this point, we have just switched to displaying a different document than we
|
||||
// we previously displaying. This means we need to abort any panning/zooming animations
|
||||
// that are in progress and send an updated display port request to browser.js as soon
|
||||
// as possible. We accomplish this by passing true to abortPanZoomAnimation, which
|
||||
// sends the request after aborting the animation. The display port request is actually
|
||||
// a full viewport update, which is fine because if browser.js has somehow moved to
|
||||
// as possible. The call to PanZoomController.abortAnimation accomplishes this by calling the
|
||||
// setForceRedraw function, which sends the viewport to gecko. The display port request is
|
||||
// actually a full viewport update, which is fine because if browser.js has somehow moved to
|
||||
// be out of sync with this first-paint viewport, then we force them back in sync.
|
||||
abortPanZoomAnimation();
|
||||
|
||||
|
|
|
@ -226,6 +226,7 @@ public class PanZoomController
|
|||
// transitions.
|
||||
synchronized (mTarget.getLock()) {
|
||||
mTarget.setViewportMetrics(getValidViewportMetrics());
|
||||
mTarget.setForceRedraw();
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче