From 540fdf89b1432f99e3c01d6ec838d434609eefb7 Mon Sep 17 00:00:00 2001 From: Huihong Luo Date: Fri, 25 Jun 2021 13:59:39 -0700 Subject: Reparent surface control for Webview overlay When the root surface control changes, the parent of the Webview surface control must be changed. Bug: 191900007 Test: switch app, or turn on/off screen Change-Id: Ib7b34133776fd5944afc638bfee471afe6a17349 --- libs/hwui/renderthread/RenderThread.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'libs/hwui/renderthread/RenderThread.cpp') diff --git a/libs/hwui/renderthread/RenderThread.cpp b/libs/hwui/renderthread/RenderThread.cpp index 524407d2b9b0..f83c0a4926f9 100644 --- a/libs/hwui/renderthread/RenderThread.cpp +++ b/libs/hwui/renderthread/RenderThread.cpp @@ -98,6 +98,10 @@ ASurfaceControlFunctions::ASurfaceControlFunctions() { LOG_ALWAYS_FATAL_IF(transactionApplyFunc == nullptr, "Failed to find required symbol ASurfaceTransaction_apply!"); + transactionReparentFunc = (AST_reparent)dlsym(handle_, "ASurfaceTransaction_reparent"); + LOG_ALWAYS_FATAL_IF(transactionReparentFunc == nullptr, + "Failed to find required symbol transactionReparentFunc!"); + transactionSetVisibilityFunc = (AST_setVisibility)dlsym(handle_, "ASurfaceTransaction_setVisibility"); LOG_ALWAYS_FATAL_IF(transactionSetVisibilityFunc == nullptr, -- cgit v1.2.3