Changeset 65905 in webkit
- Timestamp:
- Aug 24, 2010 9:15:46 AM (14 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 14 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r65903 r65905 1 2010-08-24 Pavel Feldman <pfeldman@chromium.org> 2 3 Reviewed by Yury Semikhatsky. 4 5 Web Inspector: Trace to the style that contributes to 6 the computed styles panel. 7 https://bugs.webkit.org/show_bug.cgi?id=44448 8 9 * inspector/elements-panel-styles-expected.txt: 10 * inspector/elements-tests.js: 11 (frontend_getSelectedElementStyles): 12 (frontend_dumpStyleTreeItem): 13 * inspector/styles-computed-trace-expected.txt: Added. 14 * inspector/styles-computed-trace.html: Added. 15 * inspector/styles-disable-inherited-expected.txt: 16 * inspector/styles-disable-inherited.html: 17 * inspector/styles-disable-then-delete-expected.txt: 18 * inspector/styles-source-lines-inline-expected.txt: 19 1 20 2010-08-24 Csaba Osztrogonác <ossy@webkit.org> 2 21 -
trunk/LayoutTests/inspector/elements-panel-styles-expected.txt
r61010 r65905 3 3 [expanded] () 4 4 color: blue; 5 .foo, .foo::before - blue resources/elements-panel-styles.css:15 6 /-- overloaded --/ .foo - black resources/elements-panel-styles.css:10 5 7 display: none; 8 element.style - none 9 /-- overloaded --/ div - block user agent stylesheet 6 10 font-family: serif; 11 #container - serif resources/elements-panel-styles.css:5 7 12 font-size: 14px; 8 height: auto; 13 #container - 14px resources/elements-panel-styles.css:5 14 /-- overloaded --/ body - 12px resources/elements-panel-styles.css:1 9 15 margin-bottom: 2px; 16 .foo - 2px resources/elements-panel-styles.css:10 10 17 margin-left: 0px; 18 .foo - 0px resources/elements-panel-styles.css:10 11 19 margin-right: 0px; 20 .foo - 0px resources/elements-panel-styles.css:10 12 21 margin-top: 10px; 13 width: auto; 22 .foo - 10px resources/elements-panel-styles.css:10 14 23 15 [expanded] element.style { ( element’s “style” attribute)24 [expanded] element.style { () 16 25 display: none; 17 26 -
trunk/LayoutTests/inspector/elements-tests.js
r62630 r65905 61 61 if (section.element.previousSibling && section.element.previousSibling.className === "styles-sidebar-separator") 62 62 result.push("======== " + section.element.previousSibling.textContent + " ========"); 63 result.push((section.expanded ? "[expanded] " : "[collapsed] ") + section.titleElement.textContent + " (" + section.subtitleAsText + ")");63 result.push((section.expanded ? "[expanded] " : "[collapsed] ") + section.titleElement.textContent + " (" + section.subtitleAsTextForTest + ")"); 64 64 section.expand(); 65 65 frontend_dumpStyleTreeOutline(section.propertiesTreeOutline, result); … … 93 93 function frontend_dumpStyleTreeItem(treeItem, result, prefix) 94 94 { 95 // Filter out width and height properties in order to minimize 96 // potential diffs. 97 if (!treeItem.listItemElement.textContent.indexOf("width") || 98 !treeItem.listItemElement.textContent.indexOf("height")) 99 return; 100 95 101 if (treeItem.listItemElement.hasStyleClass("inherited")) 96 102 return; … … 100 106 if (treeItem.listItemElement.hasStyleClass("disabled")) 101 107 typePrefix += "/-- disabled --/ "; 102 result.push(prefix + typePrefix + treeItem.listItemElement.textContent); 108 var textContent = treeItem.listItemElement.textContent; 109 110 // Add non-selectable url text. 111 var textData = treeItem.listItemElement.querySelector("[data-uncopyable]"); 112 if (textData) 113 textContent += textData.getAttribute("data-uncopyable"); 114 115 result.push(prefix + typePrefix + textContent); 103 116 treeItem.expand(); 104 117 var children = treeItem.children; -
trunk/LayoutTests/inspector/styles-disable-inherited-expected.txt
r59243 r65905 2 2 3 3 Before disable 4 [expanded] element.style { ( element’s “style” attribute)4 [expanded] element.style { () 5 5 6 6 ======== Matched CSS Rules ======== … … 9 9 10 10 ======== Inherited from div#container ======== 11 [expanded] Style Attribute { ( element’s “style” attribute)11 [expanded] Style Attribute { () 12 12 font-weight: bold; 13 13 14 14 15 15 After disable: 16 [expanded] element.style { ( element’s “style” attribute)16 [expanded] element.style { () 17 17 18 18 ======== Matched CSS Rules ======== -
trunk/LayoutTests/inspector/styles-disable-inherited.html
r59381 r65905 50 50 testController.results.push("After disable:"); 51 51 testController.results = testController.results.concat(frontend_getSelectedElementStyles(true)); 52 testController.notifyDone( window.__result);52 testController.notifyDone(testController.results); 53 53 } 54 54 frontend_selectElementAndRun(testController, "nested", reportResults); -
trunk/LayoutTests/inspector/styles-disable-then-delete-expected.txt
r59381 r65905 2 2 3 3 Before disable 4 [expanded] element.style { ( element’s “style” attribute)4 [expanded] element.style { () 5 5 font-weight: bold; 6 6 7 7 8 8 After disable 9 [expanded] element.style { ( element’s “style” attribute)9 [expanded] element.style { () 10 10 /-- overloaded --/ /-- disabled --/ font-weight: bold; 11 11 12 12 13 13 After delete 14 [expanded] element.style { ( element’s “style” attribute)14 [expanded] element.style { () 15 15 16 16 -
trunk/LayoutTests/inspector/styles-source-lines-inline-expected.txt
r62630 r65905 2 2 3 3 4 [expanded] element.style { ( element’s “style” attribute)4 [expanded] element.style { () 5 5 display: none; 6 6 … … 13 13 14 14 15 [expanded] element.style { ( element’s “style” attribute)15 [expanded] element.style { () 16 16 17 17 ======== Matched CSS Rules ======== -
trunk/LayoutTests/platform/chromium/test_expectations.txt
r65884 r65905 3134 3134 //BUG41968 LINUX WIN : svg/hittest/svg-rect-hit.html = TEXT 3135 3135 3136 BUGWK43720 WIN : http/tests/inspector-enabled/console-log-before-frame-navigation.html = TEXT3137 3138 3136 // Failure caused by r64749 3139 3137 BUGSATISH: fast/speech/input-text-speechbutton.html = TIMEOUT -
trunk/WebCore/ChangeLog
r65904 r65905 1 2010-08-24 Pavel Feldman <pfeldman@chromium.org> 2 3 Reviewed by Yury Semikhatsky. 4 5 Web Inspector: Trace to the style that contributes to 6 the computed styles panel. 7 https://bugs.webkit.org/show_bug.cgi?id=44448 8 9 Test: inspector/styles-computed-trace.html 10 11 * English.lproj/localizedStrings.js: 12 * inspector/front-end/Section.js: 13 (WebInspector.Section.prototype.set subtitle): 14 (WebInspector.Section.prototype.get subtitleAsTextForTest): 15 * inspector/front-end/StylesSidebarPane.js: 16 (WebInspector.StylesSidebarPane.prototype._refreshUpdate): 17 (WebInspector.StylesSidebarPane.prototype._rebuildUpdate): 18 (WebInspector.StylesSidebarPane.prototype._rebuildStyleRules): 19 (WebInspector.StylesSidebarPane.prototype._refreshSectionsForStyleRules): 20 (WebInspector.StylesSidebarPane.prototype._rebuildSectionsForStyleRules): 21 (WebInspector.StylePropertiesSection.linkifyUncopyable): 22 (WebInspector.StylePropertiesSection): 23 (WebInspector.StylePropertiesSection.prototype.isPropertyInherited): 24 (WebInspector.StylePropertiesSection.prototype.isPropertyOverloaded): 25 (WebInspector.StylePropertiesSection.prototype.isPropertyDisabled): 26 (WebInspector.StylePropertiesSection.prototype.update): 27 (WebInspector.StylePropertiesSection.prototype.onpopulate): 28 (WebInspector.ComputedStylePropertiesSection): 29 (WebInspector.ComputedStylePropertiesSection.prototype.collapse): 30 (WebInspector.ComputedStylePropertiesSection.prototype._isPropertyInherited): 31 (WebInspector.ComputedStylePropertiesSection.prototype.update): 32 (WebInspector.ComputedStylePropertiesSection.prototype.onpopulate): 33 (WebInspector.ComputedStylePropertiesSection.prototype.rebuildComputedTrace): 34 (WebInspector.BlankStylePropertiesSection): 35 * inspector/front-end/inspector.css: 36 (.styles-section a::before): 37 * inspector/front-end/inspector.js: 38 (WebInspector.documentClick.followLink): 39 (WebInspector.documentClick): 40 (WebInspector.linkifyResourceAsNode): 41 1 42 2010-08-24 Daniel Cheng <dcheng@chromium.org> 2 43 -
trunk/WebCore/inspector/front-end/Section.js
r61494 r65905 83 83 return; 84 84 this._subtitle = x; 85 this.subtitleElement. setAttribute("data-uncopyable", x);85 this.subtitleElement.textContent = x; 86 86 }, 87 87 88 get subtitleAsText ()88 get subtitleAsTextForTest() 89 89 { 90 var result = ""; 91 var data = this.subtitleElement.getAttribute("data-uncopyable"); 92 if (data) 93 result += data; 90 var result = this.subtitleElement.textContent; 94 91 var child = this.subtitleElement.querySelector("[data-uncopyable]"); 95 92 if (child) { -
trunk/WebCore/inspector/front-end/StylesSidebarPane.js
r65806 r65905 161 161 this._refreshSectionsForStyleRules(styleRules, usedProperties, disabledComputedProperties, editedSection); 162 162 } 163 // Trace the computed style. 164 this.sections[0][0].rebuildComputedTrace(this.sections[0]); 163 165 }, 164 166 … … 174 176 this.sections[0] = this._rebuildSectionsForStyleRules(styleRules, usedProperties, disabledComputedProperties, 0); 175 177 var anchorElement = this.sections[0].inheritedPropertiesSeparatorElement; 178 // Trace the computed style. 179 this.sections[0][0].rebuildComputedTrace(this.sections[0]); 176 180 177 181 for (var i = 0; i < styles.pseudoElements.length; ++i) { … … 224 228 for (var name in styles.styleAttributes) { 225 229 var attrStyle = { style: new WebInspector.CSSStyleDeclaration(styles.styleAttributes[name]), editable: false }; 226 attrStyle.subtitle = WebInspector.UIString("element’s “%s” attribute", name);227 230 attrStyle.selectorText = WebInspector.panels.elements.treeOutline.nodeNameToCorrectCase(node.nodeName) + "[" + name; 228 231 if (node.getAttribute(name)) … … 235 238 if (styles.inlineStyle && node.nodeType === Node.ELEMENT_NODE) { 236 239 var inlineStyle = { selectorText: "element.style", style: new WebInspector.CSSStyleDeclaration(styles.inlineStyle), isAttribute: true }; 237 inlineStyle.subtitle = WebInspector.UIString("element’s “%s” attribute", "style");238 240 styleRules.push(inlineStyle); 239 241 } … … 263 265 if (this._containsInherited(parentStyles.inlineStyle)) { 264 266 var inlineStyle = { selectorText: WebInspector.UIString("Style Attribute"), style: new WebInspector.CSSStyleDeclaration(parentStyles.inlineStyle), isAttribute: true, isInherited: true }; 265 inlineStyle.subtitle = WebInspector.UIString("element’s “%s” attribute", "style");266 267 if (!separatorInserted) { 267 268 insertInheritedNodeSeparator(parentNode); … … 387 388 var styleRule = styleRules[i]; 388 389 var section = styleRule.section; 389 if (styleRule.computedStyle) 390 section.disabledComputedProperties = disabledComputedProperties; 391 section._usedProperties = (styleRule.usedProperties || usedProperties); 392 section.update((section === editedSection) || styleRule.computedStyle); 390 if (styleRule.computedStyle) { 391 section._disabledComputedProperties = disabledComputedProperties; 392 section._usedProperties = usedProperties; 393 section.update(); 394 } else { 395 section._usedProperties = styleRule.usedProperties; 396 section.update(section === editedSection); 397 } 393 398 } 394 399 }, … … 429 434 editable = true; 430 435 431 var section = new WebInspector.StylePropertiesSection(styleRule, styleRule.subtitle, styleRule.computedStyle, (styleRule.usedProperties || usedProperties), editable, styleRule.isInherited, lastWasSeparator);432 436 if (computedStyle) 433 section.disabledComputedProperties = disabledComputedProperties; 437 var section = new WebInspector.ComputedStylePropertiesSection(styleRule, usedProperties, disabledComputedProperties, styleRules); 438 else 439 var section = new WebInspector.StylePropertiesSection(styleRule, editable, styleRule.isInherited, lastWasSeparator); 434 440 section.pane = this; 435 441 section.expanded = true; … … 597 603 WebInspector.ComputedStyleSidebarPane.prototype.__proto__ = WebInspector.SidebarPane.prototype; 598 604 599 WebInspector.StylePropertiesSection = function(styleRule, subtitle, computedStyle, usedProperties,editable, isInherited, isFirstSection)605 WebInspector.StylePropertiesSection = function(styleRule, editable, isInherited, isFirstSection) 600 606 { 601 607 WebInspector.PropertiesSection.call(this, ""); … … 606 612 this.titleElement.appendChild(this._selectorElement); 607 613 608 if (!computedStyle) { 609 var openBrace = document.createElement("span"); 610 openBrace.textContent = " {"; 611 this.titleElement.appendChild(openBrace); 612 613 var closeBrace = document.createElement("div"); 614 closeBrace.textContent = "}"; 615 this.element.appendChild(closeBrace); 616 } 614 var openBrace = document.createElement("span"); 615 openBrace.textContent = " {"; 616 this.titleElement.appendChild(openBrace); 617 618 var closeBrace = document.createElement("div"); 619 closeBrace.textContent = "}"; 620 this.element.appendChild(closeBrace); 617 621 618 622 this._selectorElement.addEventListener("dblclick", this._handleSelectorDoubleClick.bind(this), false); … … 621 625 this.styleRule = styleRule; 622 626 this.rule = this.styleRule.rule; 623 this.computedStyle = computedStyle; 624 this.editable = (editable && !computedStyle); 627 this.editable = editable; 625 628 this.isInherited = isInherited; 626 629 … … 633 636 this.editable = false; 634 637 635 this._usedProperties = usedProperties;638 this._usedProperties = styleRule.usedProperties; 636 639 637 640 if (this.rule) 638 641 this.titleElement.addStyleClass("styles-selector"); 639 642 640 if (computedStyle) { 641 this.element.addStyleClass("computed-style"); 642 this.headerElement.addStyleClass("hidden"); 643 } else { 644 if (!subtitle) { 645 function linkifyUncopyable(url, line) 646 { 647 var link = WebInspector.linkifyResourceAsNode(url, "resources", line + 1); 648 link.setAttribute("data-uncopyable", link.textContent); 649 link.textContent = ""; 650 return link; 651 } 652 653 if (this.styleRule.parentStyleSheet && this.styleRule.parentStyleSheet.href) 654 this.subtitleElement.appendChild(linkifyUncopyable(this.styleRule.parentStyleSheet.href, this.rule.sourceLine)); 655 else if (isUserAgent) 656 subtitle = WebInspector.UIString("user agent stylesheet"); 657 else if (isUser) 658 subtitle = WebInspector.UIString("user stylesheet"); 659 else if (isViaInspector) 660 subtitle = WebInspector.UIString("via inspector"); 661 else 662 this.subtitleElement.appendChild(linkifyUncopyable(this.rule.documentURL, this.rule.sourceLine)); 663 } 664 if (isInherited) 665 this.element.addStyleClass("show-inherited"); // This one is related to inherited rules, not compted style. 666 if (subtitle) 667 this.subtitle = subtitle; 643 function linkifyUncopyable(url, line) 644 { 645 var link = WebInspector.linkifyResourceAsNode(url, "resources", line + 1); 646 link.setAttribute("data-uncopyable", link.textContent); 647 link.textContent = ""; 648 return link; 668 649 } 650 651 var subtitle = ""; 652 if (this.styleRule.parentStyleSheet && this.styleRule.parentStyleSheet.href) 653 this.subtitleElement.appendChild(linkifyUncopyable(this.styleRule.parentStyleSheet.href, this.rule.sourceLine)); 654 else if (isUserAgent) 655 subtitle = WebInspector.UIString("user agent stylesheet"); 656 else if (isUser) 657 subtitle = WebInspector.UIString("user stylesheet"); 658 else if (isViaInspector) 659 subtitle = WebInspector.UIString("via inspector"); 660 else if (this.rule && this.rule.documentURL) 661 this.subtitleElement.appendChild(linkifyUncopyable(this.rule.documentURL, this.rule.sourceLine)); 662 663 if (isInherited) 664 this.element.addStyleClass("show-inherited"); // This one is related to inherited rules, not compted style. 665 if (subtitle) 666 this.subtitle = subtitle; 669 667 670 668 this.identifier = styleRule.selectorText; … … 677 675 678 676 WebInspector.StylePropertiesSection.prototype = { 679 get usedProperties()680 {681 return this._usedProperties || {};682 },683 684 set usedProperties(x)685 {686 this._usedProperties = x;687 this.update();688 },689 690 677 collapse: function(dontRememberState) 691 678 { … … 700 687 return !(property in WebInspector.StylesSidebarPane.InheritedProperties); 701 688 } 702 703 if (!this.computedStyle || !this._usedProperties || this.noAffect) 704 return false; 705 // These properties should always show for Computed Style. 706 var alwaysShowComputedProperties = { "display": true, "height": true, "width": true }; 707 return !(property in this.usedProperties) && !(property in alwaysShowComputedProperties) && !(property in this.disabledComputedProperties); 689 return false; 708 690 }, 709 691 710 692 isPropertyOverloaded: function(property, shorthand) 711 693 { 712 if ( this.computedStyle ||!this._usedProperties || this.noAffect)694 if (!this._usedProperties || this.noAffect) 713 695 return false; 714 696 … … 718 700 } 719 701 720 var used = (property in this. usedProperties);702 var used = (property in this._usedProperties); 721 703 if (used || !shorthand) 722 704 return !used; … … 727 709 for (var j = 0; j < longhandProperties.length; ++j) { 728 710 var individualProperty = longhandProperties[j]; 729 if (individualProperty in this. usedProperties)711 if (individualProperty in this._usedProperties) 730 712 return false; 731 713 } … … 734 716 }, 735 717 718 isPropertyDisabled: function(property) 719 { 720 if (!this.styleRule.style.__disabledPropertyValues) 721 return false; 722 return property in this.styleRule.style.__disabledPropertyValues; 723 }, 724 736 725 update: function(full) 737 726 { 738 if (full || this.computedStyle) {727 if (full) { 739 728 this.propertiesTreeOutline.removeChildren(); 740 729 this.populated = false; … … 746 735 } 747 736 } 748 749 737 this.afterUpdate(); 750 738 }, … … 765 753 var disabledProperties = style.__disabledPropertyValues || {}; 766 754 767 varuniqueProperties = [];755 this.uniqueProperties = []; 768 756 for (var i = 0; i < style.length; ++i) 769 uniqueProperties.push(style[i]);757 this.uniqueProperties.push(style[i]); 770 758 771 759 for (var name in disabledProperties) 772 uniqueProperties.push(name);773 774 uniqueProperties.sort();775 776 for (var i = 0; i < uniqueProperties.length; ++i) {777 var name = uniqueProperties[i];760 this.uniqueProperties.push(name); 761 762 this.uniqueProperties.sort(); 763 764 for (var i = 0; i < this.uniqueProperties.length; ++i) { 765 var name = this.uniqueProperties[i]; 778 766 var disabled = name in disabledProperties; 779 if (!disabled && this.disabledComputedProperties && !(name in this.usedProperties) && name in this.disabledComputedProperties)780 disabled = true;781 782 767 var shorthand = !disabled ? style.getPropertyShorthand(name) : null; 783 768 … … 921 906 WebInspector.StylePropertiesSection.prototype.__proto__ = WebInspector.PropertiesSection.prototype; 922 907 908 WebInspector.ComputedStylePropertiesSection = function(styleRule, usedProperties, disabledComputedProperties) 909 { 910 WebInspector.PropertiesSection.call(this, ""); 911 this.headerElement.addStyleClass("hidden"); 912 this.element.className = "styles-section monospace first-styles-section read-only computed-style"; 913 this.styleRule = styleRule; 914 this._usedProperties = usedProperties; 915 this._disabledComputedProperties = disabledComputedProperties; 916 this._alwaysShowComputedProperties = { "display": true, "height": true, "width": true }; 917 this.computedStyle = true; 918 this._propertyTreeElements = {}; 919 this._expandedPropertyNames = {}; 920 } 921 922 WebInspector.ComputedStylePropertiesSection.prototype = { 923 collapse: function(dontRememberState) 924 { 925 // Overriding with empty body. 926 }, 927 928 _isPropertyInherited: function(property) 929 { 930 return !(property in this._usedProperties) && !(property in this._alwaysShowComputedProperties) && !(property in this._disabledComputedProperties); 931 }, 932 933 update: function() 934 { 935 this._expandedPropertyNames = {}; 936 for (var name in this._propertyTreeElements) { 937 if (this._propertyTreeElements[name].expanded) 938 this._expandedPropertyNames[name] = true; 939 } 940 this._propertyTreeElements = {}; 941 this.propertiesTreeOutline.removeChildren(); 942 this.populated = false; 943 }, 944 945 onpopulate: function() 946 { 947 var style = this.styleRule.style; 948 var uniqueProperties = []; 949 for (var i = 0; i < style.length; ++i) 950 uniqueProperties.push(style[i]); 951 uniqueProperties.sort(); 952 953 this._propertyTreeElements = {}; 954 for (var i = 0; i < uniqueProperties.length; ++i) { 955 var name = uniqueProperties[i]; 956 var inherited = this._isPropertyInherited(name); 957 var item = new WebInspector.StylePropertyTreeElement(this.styleRule, style, name, false, inherited, false, false); 958 this.propertiesTreeOutline.appendChild(item); 959 this._propertyTreeElements[name] = item; 960 } 961 }, 962 963 rebuildComputedTrace: function(sections) 964 { 965 for (var i = 0; i < sections.length; ++i) { 966 var section = sections[i]; 967 if (section.computedStyle || section instanceof WebInspector.BlankStylePropertiesSection) 968 continue; 969 970 for (var j = 0; j < section.uniqueProperties.length; ++j) { 971 var name = section.uniqueProperties[j]; 972 if (section.isPropertyDisabled(name)) 973 continue; 974 if (section.isInherited && !(name in WebInspector.StylesSidebarPane.InheritedProperties)) 975 continue; 976 977 var treeElement = this._propertyTreeElements[name]; 978 if (treeElement) { 979 var selectorText = section.styleRule.selectorText; 980 var value = section.styleRule.style.getPropertyValue(name); 981 var title = "<span style='color: gray'>" + selectorText + "</span> - " + value; 982 var subtitle = " <span style='float:right'>" + section.subtitleElement.innerHTML + "</span>"; 983 var childElement = new TreeElement(title + subtitle, null, false); 984 treeElement.appendChild(childElement); 985 if (section.isPropertyOverloaded(name)) 986 childElement.listItemElement.addStyleClass("overloaded"); 987 } 988 } 989 } 990 991 // Restore expanded state after update. 992 for (var name in this._expandedPropertyNames) { 993 if (name in this._propertyTreeElements) 994 this._propertyTreeElements[name].expand(); 995 } 996 } 997 } 998 999 WebInspector.ComputedStylePropertiesSection.prototype.__proto__ = WebInspector.PropertiesSection.prototype; 1000 923 1001 WebInspector.BlankStylePropertiesSection = function(defaultSelectorText) 924 1002 { 925 WebInspector.StylePropertiesSection.call(this, {selectorText: defaultSelectorText, rule: {isViaInspector: true}}, "", false, {}, false); 926 1003 WebInspector.StylePropertiesSection.call(this, {selectorText: defaultSelectorText, rule: {isViaInspector: true}}, true, false, false); 927 1004 this.element.addStyleClass("blank-section"); 928 1005 } … … 963 1040 { 964 1041 this.element.removeStyleClass("blank-section"); 965 966 1042 this.styleRule = styleRule; 967 1043 this.rule = styleRule.rule; 968 this.computedStyle = false;969 this.editable = true;970 1044 this.identifier = styleRule.selectorText + ":via inspector"; 971 972 1045 this.__proto__ = WebInspector.StylePropertiesSection.prototype; 973 1046 } -
trunk/WebCore/inspector/front-end/inspector.css
r65806 r65905 4108 4108 } 4109 4109 4110 .styles-section .subtitle::before, .styles-section .subtitlea::before {4110 .styles-section a::before { 4111 4111 content: attr(data-uncopyable); 4112 4112 } -
trunk/WebCore/inspector/front-end/inspector.js
r65809 r65905 715 715 { 716 716 // FIXME: support webkit-html-external-link links here. 717 if (WebInspector.canShowSourceLine(anchor.href, anchor. lineNumber, anchor.preferredPanel)) {717 if (WebInspector.canShowSourceLine(anchor.href, anchor.getAttribute("line_number"), anchor.getAttribute("preferred_panel"))) { 718 718 if (anchor.hasStyleClass("webkit-html-external-link")) { 719 719 anchor.removeStyleClass("webkit-html-external-link"); … … 721 721 } 722 722 723 WebInspector.showSourceLine(anchor.href, anchor. lineNumber, anchor.preferredPanel);723 WebInspector.showSourceLine(anchor.href, anchor.getAttribute("line_number"), anchor.getAttribute("preferred_panel")); 724 724 return; 725 725 } … … 1801 1801 linkText += ":" + lineNumber; 1802 1802 var node = WebInspector.linkifyURLAsNode(url, linkText, classes, false, tooltipText); 1803 node. lineNumber = lineNumber;1804 node. preferredPanel = preferredPanel;1803 node.setAttribute("line_number", lineNumber); 1804 node.setAttribute("preferred_panel", preferredPanel); 1805 1805 return node; 1806 1806 }
Note: See TracChangeset
for help on using the changeset viewer.