Bug 745243 - Wait for surfaceChanged before calling GLController.provideEGLSurface. r=kats
This commit is contained in:
@@ -135,22 +135,19 @@ public class GLController {
|
||||
return mHeight;
|
||||
}
|
||||
|
||||
synchronized void surfaceCreated() {
|
||||
mSurfaceValid = true;
|
||||
notifyAll();
|
||||
}
|
||||
|
||||
synchronized void surfaceDestroyed() {
|
||||
mSurfaceValid = false;
|
||||
notifyAll();
|
||||
}
|
||||
|
||||
synchronized void sizeChanged(int newWidth, int newHeight) {
|
||||
synchronized void surfaceChanged(int newWidth, int newHeight) {
|
||||
mWidth = newWidth;
|
||||
mHeight = newHeight;
|
||||
if (mGL != null) {
|
||||
mView.getRenderer().onSurfaceChanged((GL10)mGL, mWidth, mHeight);
|
||||
}
|
||||
mSurfaceValid = true;
|
||||
notifyAll();
|
||||
}
|
||||
|
||||
private void initEGL() {
|
||||
@@ -175,7 +172,7 @@ public class GLController {
|
||||
|
||||
if (mView.getRenderer() != null) {
|
||||
mView.getRenderer().onSurfaceCreated((GL10)mGL, mEGLConfig);
|
||||
mView.getRenderer().onSurfaceChanged((GL10)mGL, mView.getWidth(), mView.getHeight());
|
||||
mView.getRenderer().onSurfaceChanged((GL10)mGL, mWidth, mHeight);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user