Bug 1527176 - Check each child has current parent before adding it. r=geckoview-reviewers,snorp,esawin

Differential Revision: https://phabricator.services.mozilla.com/D19454

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Eitan Isaacson 2019-02-12 19:22:02 +00:00
Родитель f3d9f254c8
Коммит 29d41d67a1
1 изменённых файлов: 2 добавлений и 1 удалений

Просмотреть файл

@ -370,7 +370,8 @@ public class SessionAccessibility {
int[] children = nodeInfo.getIntArray("children");
if (children != null) {
for (int childId : children) {
if (!fromCache || getMostRecentBundle(childId) != null) {
final GeckoBundle childBundle = getMostRecentBundle(childId);
if (!fromCache || (childBundle != null && childBundle.getInt("parentId") == id)) {
// If this node is from cache, only populate with children that are cached as well.
node.addChild(mView, childId);
}