OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. |
3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com> | 3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com> |
4 * Copyright (C) 2009 Joseph Pecoraro | 4 * Copyright (C) 2009 Joseph Pecoraro |
5 * | 5 * |
6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
8 * are met: | 8 * are met: |
9 * | 9 * |
10 * 1. Redistributions of source code must retain the above copyright | 10 * 1. Redistributions of source code must retain the above copyright |
(...skipping 1287 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1298 * @param {?WebInspector.ElementsTreeOutline.UpdateRecord} updateRecord | 1298 * @param {?WebInspector.ElementsTreeOutline.UpdateRecord} updateRecord |
1299 */ | 1299 */ |
1300 _buildTagDOM: function(parentElement, tagName, isClosingTag, isDistinctTreeE
lement, updateRecord) | 1300 _buildTagDOM: function(parentElement, tagName, isClosingTag, isDistinctTreeE
lement, updateRecord) |
1301 { | 1301 { |
1302 var node = this._node; | 1302 var node = this._node; |
1303 var classes = [ "webkit-html-tag" ]; | 1303 var classes = [ "webkit-html-tag" ]; |
1304 if (isClosingTag && isDistinctTreeElement) | 1304 if (isClosingTag && isDistinctTreeElement) |
1305 classes.push("close"); | 1305 classes.push("close"); |
1306 var tagElement = parentElement.createChild("span", classes.join(" ")); | 1306 var tagElement = parentElement.createChild("span", classes.join(" ")); |
1307 tagElement.createTextChild("<"); | 1307 tagElement.createTextChild("<"); |
1308 var tagNameElement = tagElement.createChild("span", isClosingTag ? "" :
"webkit-html-tag-name"); | 1308 var tagNameElement = tagElement.createChild("span", isClosingTag ? "webk
it-html-close-tag-name" : "webkit-html-tag-name"); |
1309 tagNameElement.textContent = (isClosingTag ? "/" : "") + tagName; | 1309 tagNameElement.textContent = (isClosingTag ? "/" : "") + tagName; |
1310 if (!isClosingTag) { | 1310 if (!isClosingTag) { |
1311 if (node.hasAttributes()) { | 1311 if (node.hasAttributes()) { |
1312 var attributes = node.attributes(); | 1312 var attributes = node.attributes(); |
1313 for (var i = 0; i < attributes.length; ++i) { | 1313 for (var i = 0; i < attributes.length; ++i) { |
1314 var attr = attributes[i]; | 1314 var attr = attributes[i]; |
1315 tagElement.createTextChild(" "); | 1315 tagElement.createTextChild(" "); |
1316 this._buildAttributeDOM(tagElement, attr.name, attr.value, u
pdateRecord, false, node); | 1316 this._buildAttributeDOM(tagElement, attr.name, attr.value, u
pdateRecord, false, node); |
1317 } | 1317 } |
1318 } | 1318 } |
(...skipping 261 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1580 | 1580 |
1581 if (object) | 1581 if (object) |
1582 object.callFunction(scrollIntoView); | 1582 object.callFunction(scrollIntoView); |
1583 } | 1583 } |
1584 | 1584 |
1585 this._node.resolveToObject("", scrollIntoViewCallback); | 1585 this._node.resolveToObject("", scrollIntoViewCallback); |
1586 }, | 1586 }, |
1587 | 1587 |
1588 __proto__: TreeElement.prototype | 1588 __proto__: TreeElement.prototype |
1589 } | 1589 } |
OLD | NEW |