OLD | NEW |
1 function getInspectorHighlightJSON(nodeId, opt_frameId) | 1 function getInspectorHighlightJSON(nodeId, opt_frameId) |
2 { | 2 { |
3 var doc = document; | 3 var doc = document; |
4 if (opt_frameId) | 4 if (opt_frameId) |
5 doc = document.getElementById(opt_frameId).contentDocument; | 5 doc = document.getElementById(opt_frameId).contentDocument; |
6 return window.internals.inspectorHighlightJSON(doc.getElementById(nodeId)); | 6 return window.internals.inspectorHighlightJSON(doc.getElementById(nodeId)); |
7 } | 7 } |
8 | 8 |
9 var initialize_ElementTest = function() { | 9 var initialize_ElementTest = function() { |
10 | 10 |
(...skipping 335 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
346 function objectsExpanded() | 346 function objectsExpanded() |
347 { | 347 { |
348 var eventListenerSections = WebInspector.panels.elements.sidebarPanes.ev
entListeners.sections; | 348 var eventListenerSections = WebInspector.panels.elements.sidebarPanes.ev
entListeners.sections; |
349 for (var i = 0; i < eventListenerSections.length; ++i) { | 349 for (var i = 0; i < eventListenerSections.length; ++i) { |
350 var eventType = eventListenerSections[i]._title; | 350 var eventType = eventListenerSections[i]._title; |
351 InspectorTest.addResult(""); | 351 InspectorTest.addResult(""); |
352 InspectorTest.addResult("======== " + eventType + " ========"); | 352 InspectorTest.addResult("======== " + eventType + " ========"); |
353 var eventBarChildren = eventListenerSections[i]._eventBars.children; | 353 var eventBarChildren = eventListenerSections[i]._eventBars.children; |
354 for (var j = 0; j < eventBarChildren.length; ++j) { | 354 for (var j = 0; j < eventBarChildren.length; ++j) { |
355 var objectPropertiesSection = eventBarChildren[j]._section; | 355 var objectPropertiesSection = eventBarChildren[j]._section; |
356 InspectorTest.dumpObjectPropertySection(objectPropertiesSection,
{ | 356 InspectorTest.dumpObjectPropertySection(objectPropertiesSection,
{}); |
357 sourceName: formatSourceNameProperty | |
358 }); | |
359 } | 357 } |
360 } | 358 } |
361 callback(); | 359 callback(); |
362 } | 360 } |
363 | |
364 function formatSourceNameProperty(value) | |
365 { | |
366 return "[clipped-for-test]/" + value.replace(/(.*?\/)LayoutTests/, "Layo
utTests"); | |
367 } | |
368 } | 361 } |
369 | 362 |
370 InspectorTest.dumpObjectPropertySection = function(section, formatters) | 363 InspectorTest.dumpObjectPropertySection = function(section, formatters) |
371 { | 364 { |
372 var expandedSubstring = section.expanded ? "[expanded]" : "[collapsed]"; | 365 var expandedSubstring = section.expanded ? "[expanded]" : "[collapsed]"; |
373 var titleElement = section.titleElement.firstElementChild ? section.titleEle
ment.firstElementChild.shadowRoot.lastChild.textContent : section.titleElement.t
extContent; | 366 var titleElement = section.titleElement.firstElementChild ? section.titleEle
ment.firstElementChild.shadowRoot.lastChild.textContent : section.titleElement.t
extContent; |
374 InspectorTest.addResult(expandedSubstring + " " + titleElement + " " + secti
on.subtitleAsTextForTest); | 367 InspectorTest.addResult(expandedSubstring + " " + titleElement + " " + secti
on.subtitleAsTextForTest); |
375 if (!section.propertiesForTest) | 368 if (!section.propertiesForTest) |
376 return; | 369 return; |
377 | 370 |
(...skipping 514 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
892 function innerCallback(result) | 885 function innerCallback(result) |
893 { | 886 { |
894 InspectorTest.addResult(nodeId + ": " + result.description); | 887 InspectorTest.addResult(nodeId + ": " + result.description); |
895 callback(); | 888 callback(); |
896 } | 889 } |
897 opt_frameId = opt_frameId || ""; | 890 opt_frameId = opt_frameId || ""; |
898 InspectorTest.evaluateInPage("getInspectorHighlightJSON(\"" + nodeId + "\",
\"" + opt_frameId + "\")", innerCallback); | 891 InspectorTest.evaluateInPage("getInspectorHighlightJSON(\"" + nodeId + "\",
\"" + opt_frameId + "\")", innerCallback); |
899 } | 892 } |
900 | 893 |
901 }; | 894 }; |
OLD | NEW |