| Index: Source/devtools/front_end/elements/StylesSidebarPane.js
|
| diff --git a/Source/devtools/front_end/elements/StylesSidebarPane.js b/Source/devtools/front_end/elements/StylesSidebarPane.js
|
| index b00fb3c486c31603d884cc0eace4d9cb67fb8470..6e2b36e5fe2f17832564a9fa171f37addd969ca3 100644
|
| --- a/Source/devtools/front_end/elements/StylesSidebarPane.js
|
| +++ b/Source/devtools/front_end/elements/StylesSidebarPane.js
|
| @@ -1187,25 +1187,7 @@ WebInspector.StylePropertiesSection.prototype = {
|
|
|
| if (media.sourceURL) {
|
| var refElement = mediaDataElement.createChild("div", "subtitle");
|
| - var rawLocation;
|
| - var mediaHeader;
|
| - if (media.range) {
|
| - mediaHeader = media.header();
|
| - if (mediaHeader) {
|
| - var lineNumber = media.lineNumberInSource();
|
| - var columnNumber = media.columnNumberInSource();
|
| - console.assert(typeof lineNumber !== "undefined" && typeof columnNumber !== "undefined");
|
| - rawLocation = new WebInspector.CSSLocation(this._parentPane._target, media.sourceURL, lineNumber, columnNumber);
|
| - }
|
| - }
|
| -
|
| - var anchor;
|
| - if (rawLocation)
|
| - anchor = this._parentPane._linkifier.linkifyCSSLocation(mediaHeader.id, rawLocation);
|
| - else {
|
| - // The "linkedStylesheet" case.
|
| - anchor = WebInspector.linkifyResourceAsNode(media.sourceURL, undefined, "subtitle", media.sourceURL);
|
| - }
|
| + var anchor = this._parentPane._linkifier.linkifyMedia(media);
|
| anchor.style.float = "right";
|
| refElement.appendChild(anchor);
|
| }
|
| @@ -1448,7 +1430,6 @@ WebInspector.StylePropertiesSection.prototype = {
|
| var isSelectorMatching = matchingSelectors[currentMatch] === i;
|
| if (isSelectorMatching)
|
| ++currentMatch;
|
| - var rawLocation = new WebInspector.CSSLocation(this._parentPane._target, rule.sourceURL, rule.lineNumberInSource(i), rule.columnNumberInSource(i));
|
| var matchingSelectorClass = isSelectorMatching ? " selector-matches" : "";
|
| var selectorElement = document.createElement("span");
|
| selectorElement.className = "simple-selector" + matchingSelectorClass;
|
| @@ -1523,8 +1504,8 @@ WebInspector.StylePropertiesSection.prototype = {
|
|
|
| if (this.styleRule.sourceURL) {
|
| var firstMatchingIndex = this.styleRule.rule.matchingSelectors && this.rule.matchingSelectors.length ? this.rule.matchingSelectors[0] : 0;
|
| - var matchingSelectorLocation = new WebInspector.CSSLocation(this._parentPane._target, this.styleRule.sourceURL, this.rule.lineNumberInSource(firstMatchingIndex), this.rule.columnNumberInSource(firstMatchingIndex));
|
| - return this._parentPane._linkifier.linkifyCSSLocation(this.rule.styleSheetId, matchingSelectorLocation) || linkifyUncopyable(this.styleRule.sourceURL, this.rule.lineNumberInSource());
|
| + var matchingSelectorLocation = new WebInspector.CSSLocation(this._parentPane._target, this.rule.styleSheetId, this.styleRule.sourceURL, this.rule.lineNumberInSource(firstMatchingIndex), this.rule.columnNumberInSource(firstMatchingIndex));
|
| + return this._parentPane._linkifier.linkifyCSSLocation(matchingSelectorLocation) || linkifyUncopyable(this.styleRule.sourceURL, this.rule.lineNumberInSource());
|
| }
|
|
|
| if (!this.rule)
|
|
|