Skip to content
This repository has been archived by the owner on Jul 22, 2024. It is now read-only.

Do not overwrite first draw callback on proxified layers #1885

Merged
merged 1 commit into from
Sep 26, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ public void setSurfaceTexture(SurfaceTexture aTexture, final int aWidth, final i
Log.d(LOGTAG, "Texture already set");
return;
}
mFirstDrawCallback = aFirstDrawCallback;

if (mRenderer != null && mRenderer.isLayer()) {
// Widget is using a layer write-only surface but we also want a proxy.
if (mProxyRenderer != null) {
Expand All @@ -116,6 +116,8 @@ public void setSurfaceTexture(SurfaceTexture aTexture, final int aWidth, final i
mProxyRenderer = new UISurfaceTextureRenderer(aTexture, aWidth, aHeight);
postInvalidate();
return;
} else {
mFirstDrawCallback = aFirstDrawCallback;
}
mTexture = aTexture;
if (mRenderer != null) {
Expand Down