OLD | NEW |
1 <html> | 1 <html> |
2 <head> | 2 <head> |
3 <script type="text/javascript" src="../../http/tests/inspector-protocol/inspecto
r-protocol-test.js"></script> | 3 <script type="text/javascript" src="../../http/tests/inspector-protocol/inspecto
r-protocol-test.js"></script> |
4 <script> | 4 <script> |
5 | 5 |
6 function test() | 6 function test() |
7 { | 7 { |
8 var nodeInfo = {}; | 8 var nodeInfo = {}; |
9 InspectorTest.eventHandler["DOM.setChildNodes"] = setChildNodes; | 9 InspectorTest.eventHandler["DOM.setChildNodes"] = setChildNodes; |
10 InspectorTest.eventHandler["DOM.inspectNodeRequested"] = inspectNodeRequeste
d; | 10 InspectorTest.eventHandler["DOM.inspectNodeRequested"] = inspectNodeRequeste
d; |
11 InspectorTest.sendCommand("DOM.enable", {}); | 11 InspectorTest.sendCommand("DOM.enable", {}); |
12 InspectorTest.sendCommand("DOM.setInspectModeEnabled", { "enabled": true, hi
ghlightConfig: {} }, onSetModeEnabled); | 12 InspectorTest.sendCommand("DOM.setInspectMode", { "mode": "searchForNode", h
ighlightConfig: {} }, onSetModeEnabled); |
13 | 13 |
14 function onSetModeEnabled(message) | 14 function onSetModeEnabled(message) |
15 { | 15 { |
16 if (message.error) { | 16 if (message.error) { |
17 InspectorTest.log(message.error.message); | 17 InspectorTest.log(message.error.message); |
18 InspectorTest.completeTest(); | 18 InspectorTest.completeTest(); |
19 return; | 19 return; |
20 } | 20 } |
21 | 21 |
22 InspectorTest.sendCommand("Input.dispatchMouseEvent", { "type": "mouseMo
ved", "button": "left", "clickCount": 1, "x": 150, "y": 150 }); | 22 InspectorTest.sendCommand("Input.dispatchMouseEvent", { "type": "mouseMo
ved", "button": "left", "clickCount": 1, "x": 150, "y": 150 }); |
(...skipping 21 matching lines...) Expand all Loading... |
44 InspectorTest.completeTest(); | 44 InspectorTest.completeTest(); |
45 } | 45 } |
46 } | 46 } |
47 | 47 |
48 </script> | 48 </script> |
49 </head> | 49 </head> |
50 <body onload="runTest()"> | 50 <body onload="runTest()"> |
51 <div style="position:absolute;top:100;left:100;width:100;height:100;background:b
lack"></div> | 51 <div style="position:absolute;top:100;left:100;width:100;height:100;background:b
lack"></div> |
52 </body> | 52 </body> |
53 </html> | 53 </html> |
OLD | NEW |