------- Inspected URL: https://webkit.org/ Loading completed: true Frontend User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_4) AppleWebKit/604.1.21+ (KHTML, like Gecko) Uncaught Exceptions: - TypeError: frame.resourceForURL is not a function. (In 'frame.resourceForURL(simplifiedURL, searchChildFrames)', 'frame.resourceForURL' is undefined) (at Main.js:856:91) openURL @ Main.js:856:91 tokenTrackingControllerHighlightedRangeWasClicked @ CSSStyleDeclarationTextEditor.js:1717:33 _mouseButtonWasReleasedOverEditor @ CodeMirrorTokenTrackingController.js:425:89 handleEvent @ CodeMirrorTokenTrackingController.js:253:51 ------- * STEPS TO REPRODUCE 1. Open https://webkit.org/. 2. Inspect the WebKit logo in top left corner (h1.logo). 3. In the Styles sidebar, find "background-image: url('images/webkit.svg');" and option-click on the image URL. * EXPECTED Image opens in the Resources tab.
<rdar://problem/31946367>
I think this regressed in r215630 <https://webkit.org/b/168709>. It looks like I forgot the `frame` parameter of `WebInspector.openURL` in CSSStyleDeclarationTextEditor.js:1717. It should be: // Special case option-clicking url(...) links. if (token && /\blink\b/.test(token.type)) { let url = token.string; let baseURL = sourceCodeLocation ? sourceCodeLocation.sourceCode.url : this._style.node.ownerDocument.documentURL; const frame = null; WebInspector.openURL(absoluteURL(url, baseURL), frame, options); return; }
I confirm it regressed in https://trac.webkit.org/changeset/215630/webkit.
(In reply to Devin Rousso from comment #2) > I think this regressed in r215630 <https://webkit.org/b/168709>. It looks > like I forgot the `frame` parameter of `WebInspector.openURL` in > CSSStyleDeclarationTextEditor.js:1717. It should be: > > // Special case option-clicking url(...) links. > if (token && /\blink\b/.test(token.type)) { > let url = token.string; > let baseURL = sourceCodeLocation ? > sourceCodeLocation.sourceCode.url : > this._style.node.ownerDocument.documentURL; > > const frame = null; > WebInspector.openURL(absoluteURL(url, baseURL), frame, options); > return; > } Yes, this solves the problem. Since you just wrote the fix, do you want to post a patch?
Created attachment 308994 [details] Patch
Comment on attachment 308994 [details] Patch r=me
Comment on attachment 308994 [details] Patch Clearing flags on attachment: 308994 Committed r216166: <http://trac.webkit.org/changeset/216166>
All reviewed patches have been landed. Closing bug.