Bug 925608 - 8/8: remove mServerSurfaceValid - r=kats
This commit is contained in:
@@ -36,7 +36,6 @@ public class GLController {
|
|||||||
private static GLController sInstance;
|
private static GLController sInstance;
|
||||||
|
|
||||||
private LayerView mView;
|
private LayerView mView;
|
||||||
private boolean mServerSurfaceValid;
|
|
||||||
private int mWidth, mHeight;
|
private int mWidth, mHeight;
|
||||||
|
|
||||||
/* This is written by the compositor thread (while the UI thread
|
/* This is written by the compositor thread (while the UI thread
|
||||||
@@ -82,8 +81,6 @@ public class GLController {
|
|||||||
ThreadUtils.assertOnUiThread();
|
ThreadUtils.assertOnUiThread();
|
||||||
Log.w(LOGTAG, "GLController::serverSurfaceDestroyed() with mCompositorCreated=" + mCompositorCreated);
|
Log.w(LOGTAG, "GLController::serverSurfaceDestroyed() with mCompositorCreated=" + mCompositorCreated);
|
||||||
|
|
||||||
mServerSurfaceValid = false;
|
|
||||||
|
|
||||||
// We need to coordinate with Gecko when pausing composition, to ensure
|
// We need to coordinate with Gecko when pausing composition, to ensure
|
||||||
// that Gecko never executes a draw event while the compositor is paused.
|
// that Gecko never executes a draw event while the compositor is paused.
|
||||||
// This is sent synchronously to make sure that we don't attempt to use
|
// This is sent synchronously to make sure that we don't attempt to use
|
||||||
@@ -100,13 +97,11 @@ public class GLController {
|
|||||||
|
|
||||||
synchronized void serverSurfaceChanged(int newWidth, int newHeight) {
|
synchronized void serverSurfaceChanged(int newWidth, int newHeight) {
|
||||||
ThreadUtils.assertOnUiThread();
|
ThreadUtils.assertOnUiThread();
|
||||||
Log.w(LOGTAG, "GLController::serverSurfaceChanged(" + newWidth + ", " + newHeight + ") with mServerSurfaceValid=" + mServerSurfaceValid);
|
Log.w(LOGTAG, "GLController::serverSurfaceChanged(" + newWidth + ", " + newHeight + ")");
|
||||||
|
|
||||||
mWidth = newWidth;
|
mWidth = newWidth;
|
||||||
mHeight = newHeight;
|
mHeight = newHeight;
|
||||||
|
|
||||||
mServerSurfaceValid = true;
|
|
||||||
|
|
||||||
updateCompositor();
|
updateCompositor();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -140,10 +135,6 @@ public class GLController {
|
|||||||
mCompositorCreated = true;
|
mCompositorCreated = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isServerSurfaceValid() {
|
|
||||||
return mServerSurfaceValid;
|
|
||||||
}
|
|
||||||
|
|
||||||
private void initEGL() {
|
private void initEGL() {
|
||||||
if (mEGL != null) {
|
if (mEGL != null) {
|
||||||
return;
|
return;
|
||||||
|
|||||||
@@ -514,7 +514,7 @@ public class LayerView extends FrameLayout implements Tabs.OnTabsChangedListener
|
|||||||
* TextureView instead of a SurfaceView, the first phase is skipped.
|
* TextureView instead of a SurfaceView, the first phase is skipped.
|
||||||
*/
|
*/
|
||||||
private void onSizeChanged(int width, int height) {
|
private void onSizeChanged(int width, int height) {
|
||||||
if (!mGLController.isServerSurfaceValid() || mSurfaceView == null) {
|
if (mSurfaceView == null) {
|
||||||
surfaceChanged(width, height);
|
surfaceChanged(width, height);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user