accessible/tests/crashtests/448064.xhtml
author Ryan VanderMeulen <ryanvm@gmail.com>
Tue, 11 Feb 2020 16:42:31 +0000
branchTHUNDERBIRD550b1_2017061508_RELBRANCH
changeset 575603 9eebc3f33831424089c2159ea1a0b865c1d6e3fb
parent 405331 298b13bed1ac2a571e8ab99f6674a83cc0c54f14
child 416561 fe520e82e9666dc975f02948b9864668c8f911c9
permissions -rw-r--r--
Bug 1562666 - Close old branch THUNDERBIRD550b1_2017061508_RELBRANCH

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
</head>
<body>
<div id="mw_b">
<div id="mw_f">
<div id="mw_g" style="display: none;"/>
</div>
</div>

<div id="mw_c" style="display: none;">
<div id="mw_d">
<div id="mw_e"></div>
</div>
</div>

<input id="mw_a"/>


<script>
function dumpAccessibleNode(aNode, level) {
	var msg = "";

	try {
		msg += "name=\"" + aNode.name + "\" ";
	} catch (e) {
		msg += " noName ";
	}

	dump(msg + '\n');
}


function dumpAccessibleTree(aNode, level) {
	level = level || 0;

	dumpAccessibleNode(aNode, level);
	try {
		var child = aNode.firstChild;
		while (child) {
			dumpAccessibleTree(child, level + 1);
			child = child.nextSibling;
		}
	} catch (e) {
		dump("Error visiting child nodes: " + e + '\n');
	}
}

function A(o) {
  var acc = SpecialPowers.Cc['@mozilla.org/accessibilityService;1']
                         .getService(SpecialPowers.Ci.nsIAccessibilityService);
  return acc.getAccessibleFor(o);
}

function beginAccessible() {
  dumpAccessibleTree(A(document), 0);
}
setTimeout(beginAccessible, 100);


setTimeout(doe, 200);
function doe() {
   document.getElementById('mw_a').appendChild(document.getElementById('mw_b'));
   document.getElementById('mw_c').appendChild(document.getElementById('mw_d'));
   document.getElementById('mw_e').appendChild(document.getElementById('mw_f'));
   document.getElementById('mw_g').appendChild(document.getElementById('mw_b'));
}
</script>
</body>
</html>