Skip to content
Commit cdedc9a8 authored by Doris Liu's avatar Doris Liu
Browse files

Check whether VD tree is still valid before calling native setter

VD tree is ref-counted in both Java and native. VD's child nodes are
entirely owned by the native tree, as VD nodes in native should outlive
its Java counterparts, with one exception: when there's an infinite UI
animator running on VD, the animator may have weak reference to a few
child nodes. In the case of hidden animator running infinitely, the child
nodes would keep getting the animation pulse while the rest of the tree
would have been destroyed. To prevent the setters triggered by animation
from calling into native, we need to check whether the tree is still
valid before going down into JNI.

Bug: 28104172
Change-Id: Ie9d4bf3898c0c23e620a4747624d24b8ab779743
parent b6e1dafe
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment