android: Do not trigger a composite before Servo has finished compositing.

This commit is contained in:
Josh Matthews 2018-09-28 23:25:13 -04:00 committed by Paul Rouget
parent 74ba683e27
commit de8fae14b7
2 changed files with 5 additions and 1 deletions

View file

@ -54,6 +54,10 @@ public class Servo {
return mJNI.version();
}
public void performUpdates() {
mRunCallback.inGLThread(() -> mJNI.performUpdates());
}
public void setBatchMode(boolean mode) {
mRunCallback.inGLThread(() -> mJNI.setBatchMode(mode));
}

View file

@ -197,7 +197,7 @@ public class ServoView extends GLSurfaceView
}
if (!zoomNecessary && !scrollNecessary && mAnimating) {
requestRender();
mServo.performUpdates();
}
if (mZooming || mScrolling || mAnimating) {