<!DOCTYPEHTML>
<html> <!-- https://bugzilla.mozilla.org/show_bug.cgi?id=570341
-->
<head>
<title>Test for Bug 570341</title>
<script src="/tests/SimpleTest/SimpleTest.js"></script>
<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/>
<script> var start = Date.now(); var moments = {};
var unload = 0; var wasEnabled = true;
function collectMoments() { var win = frames[0]; var timing = (win.performance && win.performance.timing) || {};
for (let p in timing) {
moments[p] = timing[p];
}
for (let p in win) {
if (p.substring(0, 9) == "_testing_") {
moments[p.substring(9)] = win[p];
}
}
moments.evt_unload = unload;
return moments;
}
function showSequence(node) {
while (node.firstChild) {
node.firstChild.remove();
} var sequence = [];
for (var p in moments) {
sequence.push(p);
}
sequence.sort(function(a, b) {
return moments[a] - moments[b];
}); vartable = document.createElement("table");
node.appendChild(table); var row = document.createElement("tr"); table.appendChild(row); var cell = document.createElement("td");
row.appendChild(cell);
cell.appendChild(document.createTextNode("start"));
cell = document.createElement("td");
row.appendChild(cell);
cell.appendChild(document.createTextNode(start));
for (var i = 0; i < sequence.length; ++i) { var prop = sequence[i];
row = document.createElement("tr"); table.appendChild(row);
cell = document.createElement("td");
row.appendChild(cell);
cell.appendChild(document.createTextNode(prop));
cell = document.createElement("td");
row.appendChild(cell);
cell.appendChild(document.createTextNode(moments[prop]));
}
}
function checkValues() { var win = frames[0];
ok(win.performance, "window.performance is missing or not accessible for frame");
ok(!win.performance || win.performance.timing, "window.performance.timing is missing or not accessible for frame");
collectMoments();
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung ist noch experimentell.