Changeset 61494 in webkit
- Timestamp:
- Jun 19, 2010 9:47:37 AM (14 years ago)
- Location:
- trunk
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r61491 r61494 1 2010-06-19 Nikita Vasilyev <me@elv1s.ru> 2 3 Reviewed by Pavel Feldman. 4 5 Web Inspector: subtitleElement.textContent is always empty. Use subtitleAsText method instead. 6 https://bugs.webkit.org/show_bug.cgi?id=40420 7 8 * inspector/elements-tests.js: 9 (frontend_getSelectedElementStyles): 10 1 11 2010-06-19 Dimitri Glazkov <dglazkov@chromium.org> 2 12 -
trunk/LayoutTests/inspector/elements-tests.js
r61010 r61494 70 70 if (section.element.previousSibling && section.element.previousSibling.className === "styles-sidebar-separator") 71 71 result.push("======== " + section.element.previousSibling.textContent + " ========"); 72 result.push((section.expanded ? "[expanded] " : "[collapsed] ") + section.titleElement.textContent + " (" + section.subtitle Element.textContent + ")");72 result.push((section.expanded ? "[expanded] " : "[collapsed] ") + section.titleElement.textContent + " (" + section.subtitleAsText + ")"); 73 73 section.expand(); 74 74 frontend_dumpStyleTreeOutline(section.propertiesTreeOutline, result); -
trunk/WebCore/ChangeLog
r61493 r61494 1 2010-06-19 Nikita Vasilyev <me@elv1s.ru> 2 3 Reviewed by Pavel Feldman. 4 5 Web Inspector: Prevent from copying "filename.css" in Styles pane 6 https://bugs.webkit.org/show_bug.cgi?id=40420 7 8 * inspector/front-end/Section.js: 9 (WebInspector.Section.prototype.set subtitle): 10 (WebInspector.Section.prototype.get subtitleAsText): 11 * inspector/front-end/StylesSidebarPane.js: 12 (WebInspector.StylePropertiesSection): 13 * inspector/front-end/inspector.css: 14 (.styles-section .subtitle::before, .styles-section .subtitle a::before): 15 1 16 2010-06-19 Alex Milowski <alex@milowski.com> 2 17 -
trunk/WebCore/inspector/front-end/Section.js
r54769 r61494 83 83 return; 84 84 this._subtitle = x; 85 this.subtitleElement.innerHTML = x; 85 this.subtitleElement.setAttribute("data-uncopyable", x); 86 }, 87 88 get subtitleAsText() 89 { 90 var result = ""; 91 var data = this.subtitleElement.getAttribute("data-uncopyable"); 92 if (data) 93 result += data; 94 var child = this.subtitleElement.querySelector("[data-uncopyable]"); 95 if (child) { 96 var linkData = child.getAttribute("data-uncopyable"); 97 if (linkData) 98 result += linkData; 99 } 100 return result; 86 101 }, 87 102 -
trunk/WebCore/inspector/front-end/StylesSidebarPane.js
r61014 r61494 652 652 if (this.styleRule.parentStyleSheet && this.styleRule.parentStyleSheet.href) { 653 653 var url = this.styleRule.parentStyleSheet.href; 654 this.subtitleElement.appendChild(WebInspector.linkifyResourceAsNode(url, "resources", this.rule.sourceLine + 1)); 654 var link = WebInspector.linkifyResourceAsNode(url, "resources", this.rule.sourceLine + 1); 655 link.setAttribute("data-uncopyable", link.textContent); 656 link.textContent = ""; 657 this.subtitleElement.appendChild(link); 655 658 } else if (isUserAgent) 656 659 subtitle = WebInspector.UIString("user agent stylesheet"); … … 670 673 this.identifier = styleRule.selectorText; 671 674 if (this.subtitle) 672 this.identifier += ":" + this.subtitle Element.textContent;675 this.identifier += ":" + this.subtitle; 673 676 } 674 677 -
trunk/WebCore/inspector/front-end/inspector.css
r61274 r61494 4043 4043 } 4044 4044 4045 .styles-section .subtitle::before, .styles-section .subtitle a::before { 4046 content: attr(data-uncopyable); 4047 } 4048 4045 4049 .styles-section .properties { 4046 4050 display: none;
Note: See TracChangeset
for help on using the changeset viewer.