Refactoring: Pull all fullscreen code out of Document and into its own helper class
[WebKit-https.git] / PerformanceTests / Layout / system-ui-rebuild-emoji.html
1 <!DOCTYPE html>
2 <html>
3 <head>
4     <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
5     <script src="../resources/runner.js"></script>
6 <style>
7 #target {
8     display: none;
9 }
10 </style>
11 <style id="a" media="print">
12 #target {
13     display: block;
14     width: 280px;
15 }
16 </style>
17 <style id="b" media="print">
18 #target {
19     display: block;
20     width: 300px;
21 }
22 </style>
23 <style id="c" media="print">
24 #target {
25     display: block;
26     width: 290px;
27 }
28 </style>
29 </head>
30 <body>
31     <pre id="log"></pre>
32     <div id="target" style="font-family: system-ui;">
33     <p>😎</p>
34     </div>
35     <script>
36         var target = document.getElementById("target");
37         var a = document.getElementById("a");
38         var b = document.getElementById("b");
39         var c = document.getElementById("c");
40
41         function test() {
42             a.media = "screen";
43             target.offsetLeft;
44             b.media = "screen";
45             target.offsetLeft;
46             c.media = "screen";
47             target.offsetLeft;
48             a.media = "print";
49             b.media = "print";
50             c.media = "print";
51         }
52
53         PerfTestRunner.measureRunsPerSecond({ run: test });
54     </script>
55 </body>
56 </html>