tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

focus-event-after-focusing-iframes-inner.html (426B)


      1 <!DOCTYPE html>
      2 <html>
      3 <head>
      4  <meta charset="utf-8">
      5  <title>Focus event inner document</title>
      6 </head>
      7 <body>
      8 <h1>Inner</h1>
      9 <script>
     10 let innerlog = "innerlog:";
     11 
     12 window.onmessage = function(e) {
     13  if (e.data == "getlog") {
     14    parent.postMessage(innerlog, "*");
     15  }
     16 };
     17 
     18 window.onfocus = function() {
     19  innerlog += "windowfocus,";
     20 };
     21 
     22 window.onblur = function() {
     23  innerlog += "windowblur,";
     24 };
     25 </script>
     26 </body>
     27 </html>