diff options
Diffstat (limited to '')
-rw-r--r-- | dom/base/test/jsmodules/iframe_extractIntroType.html | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/dom/base/test/jsmodules/iframe_extractIntroType.html b/dom/base/test/jsmodules/iframe_extractIntroType.html new file mode 100644 index 0000000000..26c58aea6d --- /dev/null +++ b/dom/base/test/jsmodules/iframe_extractIntroType.html @@ -0,0 +1,14 @@ +<!DOCTYPE html> +<meta charset=utf-8> +<script src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"></script> +<script> + // Hook up the debugger statement to extract the calling script's + // introductionType and set it in a property on the parent global. + const {addSandboxedDebuggerToGlobal} = ChromeUtils.importESModule("resource://gre/modules/jsdebugger.sys.mjs"); + addSandboxedDebuggerToGlobal(globalThis); + var dbg = new Debugger; + dbg.addDebuggee(parent); + dbg.onDebuggerStatement = function (frame) { + parent.introType = frame.script.source.introductionType; + } +</script> |