tor-browser

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

1219985-8.html (543B)


      1 <!DOCTYPE html>
      2 <meta charset="utf-8">
      3 <title>Bug 1219985: Unsetting moz-opaque should clear the canvas even if the canvas has been created with alpha:false, and the canvas should stay opaque.</title>
      4 
      5 <div style="width: 200px; height: 200px; background-color: red;">
      6  <canvas id="c" width="200" height="200" moz-opaque="true"></canvas>
      7 </div>
      8 
      9 <script>
     10 
     11 var c = document.getElementById('c');
     12 var ctx = c.getContext('2d', { alpha: false });
     13 ctx.fillStyle = 'green';
     14 ctx.fillRect(50, 50, 100, 100);
     15 c.removeAttribute("moz-opaque");
     16 
     17 </script>