diff options
Diffstat (limited to 'libs/hwui/renderthread/CanvasContext.cpp')
-rw-r--r-- | libs/hwui/renderthread/CanvasContext.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/libs/hwui/renderthread/CanvasContext.cpp b/libs/hwui/renderthread/CanvasContext.cpp index 69885df427fb..44d0038ad47e 100644 --- a/libs/hwui/renderthread/CanvasContext.cpp +++ b/libs/hwui/renderthread/CanvasContext.cpp @@ -193,6 +193,7 @@ void CanvasContext::setSurfaceControl(ASurfaceControl* surfaceControl) { if (surfaceControl == nullptr) { setASurfaceTransactionCallback(nullptr); + setPrepareSurfaceControlForWebviewCallback(nullptr); } if (mSurfaceControl != nullptr) { @@ -914,6 +915,12 @@ bool CanvasContext::mergeTransaction(ASurfaceTransaction* transaction, ASurfaceC return true; } +void CanvasContext::prepareSurfaceControlForWebview() { + if (mPrepareSurfaceControlForWebviewCallback) { + std::invoke(mPrepareSurfaceControlForWebviewCallback); + } +} + } /* namespace renderthread */ } /* namespace uirenderer */ } /* namespace android */ |