content/html/document/test/test_bug463104.html

Sat, 03 Jan 2015 20:18:00 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Sat, 03 Jan 2015 20:18:00 +0100
branch
TOR_BUG_3246
changeset 7
129ffea94266
permissions
-rw-r--r--

Conditionally enable double key logic according to:
private browsing mode or privacy.thirdparty.isolate preference and
implement in GetCookieStringCommon and FindCookie where it counts...
With some reservations of how to convince FindCookie users to test
condition and pass a nullptr when disabling double key logic.

michael@0 1 <!DOCTYPE html>
michael@0 2 <html>
michael@0 3 <head>
michael@0 4 <title>Noninteger coordinates test</title>
michael@0 5 <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
michael@0 6 <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
michael@0 7 </head>
michael@0 8 <body>
michael@0 9 <div id="a" style="position: fixed; left: 5.5px; top: 5.5px; width: 100px; height: 100px; background: blue"></div>
michael@0 10 <p style="margin-top: 110px">
michael@0 11 <script>
michael@0 12 var a = document.getElementById("a");
michael@0 13 isnot(a, document.elementFromPoint(5, 5), "a shouldn't be found");
michael@0 14 isnot(a, document.elementFromPoint(5.25, 5.25), "a shouldn't be found");
michael@0 15 is(a, document.elementFromPoint(5.5, 5.5), "a should be found");
michael@0 16 is(a, document.elementFromPoint(5.75, 5.75), "a should be found");
michael@0 17 is(a, document.elementFromPoint(6, 6), "a should be found");
michael@0 18 is(a, document.elementFromPoint(105, 105), "a should be found");
michael@0 19 is(a, document.elementFromPoint(105.25, 105.25), "a should be found");
michael@0 20 isnot(a, document.elementFromPoint(105.5, 105.5), "a shouldn't be found");
michael@0 21 isnot(a, document.elementFromPoint(105.75, 105.75), "a shouldn't be found");
michael@0 22 isnot(a, document.elementFromPoint(106, 106), "a shouldn't be found");
michael@0 23 </script>
michael@0 24 </body>
michael@0 25 </html>

mercurial