Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / touchadjustment / context-menu-shadow-node.html
blob04d6adeb17499f686b38579c42e8c4962af5c01b
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <title>Touch Adjustment : Handle long press on a shadow DOM element - bug 96313</title>
5 <script src="../resources/js-test.js"></script>
6 <script src="resources/touchadjustment.js"></script>
7 <style>
8 #sandbox {
9 background: #00f;
10 position: absolute;
11 top: 0px;
12 left: 0px;
13 width: 100px;
14 height: 100px;
16 #description {
17 margin-top: 110px;
19 </style>
20 </head>
22 <body>
24 <div id="sandbox"></div>
25 <p id='description'></p>
26 <div id='console'></div>
28 <script>
29 var sandbox = document.getElementById('sandbox');
31 function addShadowDOM() {
32 var targetDiv = document.getElementById("sandbox");
33 var root = targetDiv.createShadowRoot();
34 var shadowDiv = document.createElement("div");
35 shadowDiv.style.width = "20px";
36 shadowDiv.style.height = "20px";
37 shadowDiv.style.background = "#ff0";
38 shadowDiv.style.position = "absolute";
39 shadowDiv.style.right = "10px";
40 shadowDiv.style.top = "10px";
41 root.appendChild(shadowDiv);
44 function runTests()
46 if (window.testRunner && window.internals && internals.touchNodeAdjustedToBestContextMenuNode) {
47 description('Test touch adjustment for context-menu gestures on a shadow-DOM element.');
48 addShadowDOM();
49 // Test that a long press centered on a shadow-DOM element does not crash.
50 testTouchPointContextMenu(touchPoint(80, 20, 10), null);
53 runTests();
54 </script>
55 </body>
56 </html>