summaryrefslogtreecommitdiffstats
path: root/layout/base/tests/input-stoppropagation.html
blob: b246a6b6da76e0966f3f2c166e9b3918655f459b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
<!doctype html>
<html>
<script src="/tests/SimpleTest/EventUtils.js"></script>
<script>
function onLoad() {
  let input2 = document.getElementById("input2");
  input2.addEventListener("focus", e => {
    e.stopImmediatePropagation();
  });
  document.getElementById("input1").focus();
  synthesizeKey("KEY_Tab");
  synthesizeKey("KEY_Tab", {shiftKey: true});
  synthesizeKey("KEY_Tab");
}
</script>
<body onload="onLoad()">
  <input type="text" id="input1"></input>
  <input type="text" id="input2"></input>
</body>
</html>