forked from mirrors/gecko-dev
# ignore-this-changeset Differential Revision: https://phabricator.services.mozilla.com/D35951 --HG-- extra : source : 62f3501af4bc1c0bd1ee1977a28aee04706a6663
15 lines
440 B
JavaScript
15 lines
440 B
JavaScript
function send_ping() {
|
|
window.dispatchEvent(new Event("ping"));
|
|
}
|
|
send_ping(); // ping (=1)
|
|
|
|
window.addEventListener("load", function() {
|
|
send_ping(); // ping (=2)
|
|
|
|
// Append a script which should call |foo|, before the encoding of this script
|
|
// bytecode.
|
|
var script = document.createElement("script");
|
|
script.type = "text/javascript";
|
|
script.innerText = "send_ping();"; // ping (=3)
|
|
document.head.appendChild(script);
|
|
});
|