1 <!DOCTYPE HTML PUBLIC
"-//IETF//DTD HTML//EN">
4 <script src=
"../../resources/js-test.js"></script>
8 description("Click events should propagate in disconnected DOM trees.");
10 var clickedOnParent
= false;
11 var clickedOnChild
= false;
13 var parent
= document
.createElement('div');
14 var child
= document
.createElement('div');
15 parent
.appendChild(child
);
16 parent
.addEventListener('click', function(e
) { clickedOnParent
= true; } );
17 child
.addEventListener('click', function(e
) { clickedOnChild
= true; } );
20 shouldBeTrue("clickedOnParent");
21 shouldBeTrue("clickedOnChild");