Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix that the reparented items outside mask clip rect still could be t…
…ouched. When reattaching the current node, the masks of all its descendants need to be recalculated since IMask caches the index which means the distance to Mask node. Reported at https://forum.cocos.org/t/topic/163455/238?u=dumganhar There are two relevant PR requests: ## 1. #8313 This PR could not fix the issue totally, there is a currMask cache which will be used for all current node's descendants, but descendants's IMask may have different 'index' value which indicates the distance to the Mask node. public reattach (): void { let currMask; this.node.walk((node) => { if (!currMask) { currMask = _searchComponentsInParent(node as Node, NodeEventProcessor._comp); } ...... }); } ## 2. #9363 This PR made _searchComponentsInParent as instance method but in 'reattach', it will always invoke '_searchComponentsInParent' for the current node.
- Loading branch information