summaryrefslogtreecommitdiffstats
path: root/layout/reftests/font-face/restore-size-detector-iframe.html
diff options
context:
space:
mode:
authorMatt A. Tobin <mattatobin@localhost.localdomain>2018-02-02 04:16:08 -0500
committerMatt A. Tobin <mattatobin@localhost.localdomain>2018-02-02 04:16:08 -0500
commit5f8de423f190bbb79a62f804151bc24824fa32d8 (patch)
tree10027f336435511475e392454359edea8e25895d /layout/reftests/font-face/restore-size-detector-iframe.html
parent49ee0794b5d912db1f95dce6eb52d781dc210db5 (diff)
downloadUXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.gz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.lz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.xz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.zip
Add m-esr52 at 52.6.0
Diffstat (limited to 'layout/reftests/font-face/restore-size-detector-iframe.html')
-rw-r--r--layout/reftests/font-face/restore-size-detector-iframe.html32
1 files changed, 32 insertions, 0 deletions
diff --git a/layout/reftests/font-face/restore-size-detector-iframe.html b/layout/reftests/font-face/restore-size-detector-iframe.html
new file mode 100644
index 000000000..3cc72f877
--- /dev/null
+++ b/layout/reftests/font-face/restore-size-detector-iframe.html
@@ -0,0 +1,32 @@
+<!DOCTYPE HTML>
+<html>
+<head>
+ <title>Resize-notifying IFRAME</title>
+ <script type="application/ecmascript">
+
+ var gTarget;
+
+ /*
+ * the test is done after the width becomes narrower (immediately)
+ * and then comes back to the same size. However, the two things
+ * might happen at once.
+ */
+ function arm() {
+ gTarget = window.innerWidth;
+ window.addEventListener("resize", got_resize, false);
+ setTimeout(got_resize, 200);
+ }
+
+ function got_resize() {
+ if (window.innerWidth == gTarget) {
+ gTarget = -1;
+ // Remove the class="reftest-wait" from the top window
+ window.top.document.documentElement.removeAttribute("class");
+ }
+ }
+
+ </script>
+</head>
+<body>
+</body>
+</html>