Chromium Code Reviews
Help | Chromium Project | Gerrit Changes | Sign in
(320)

Issue 2893073002: DevTools: introduce ResourceMapping (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
4 months ago by lushnikov
Modified:
3 months, 1 week ago
Reviewers:
dgozman
CC:
chromium-reviews, caseq+blink_chromium.org, lushnikov+blink_chromium.org, pfeldman+blink_chromium.org, apavlov+blink_chromium.org, devtools-reviews_chromium.org, blink-reviews, pfeldman, kozyatinskiy+blink_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

DevTools: introduce ResourceMapping This patch splits out ResourceMapping from NetworkProject. ResourceMapping creates UISourceCodes for resources which are not handled by CSS Mappings and JS Mappings, such as images, fonts and html documents. ResourceMapping is structured like this: - class ResourceMapping provides uiLocation to rawLocation mapping for both CSSWorkspaceBinding and DebuggerWorkspaceBinding. ResourceMapping observes resourceTreeModels and creates ModelInfo for each. - class ResourceMaping.ModelInfo is created per resourceTreeModel to manage model-associated UISourceCodes - class ResourceMapping.Binding binds UISourceCode to multiple identical resources IMPORTANT: The new ResourceMapping also merges UISourceCodes across frames. NOTE: Because there are inline scripts and inline styles, HTML UISourceCodes are needed by both CSSWorkspaceBinding and DebuggerWorkspaceBinding to implement rawLocationToUILocation / uiLocationToRawLocation methods. Both CSSWorkspaceBinding and DebuggerWorkspaceBinding refer to ResourceMapping for this reason. R=dgozman BUG=670180 Review-Url: https://codereview.chromium.org/2893073002 Cr-Commit-Position: refs/heads/master@{#478891} Committed: https://chromium.googlesource.com/chromium/src/+/19a7ba263cc0eff46ac4752bbd04e12bb4f3dc31

Patch Set 1 #

Patch Set 2 : cleanup test #

Total comments: 12

Patch Set 3 : address comments #

Patch Set 4 : rebaseline #

Total comments: 8

Patch Set 5 : address comments #

Total comments: 18

Patch Set 6 : address comments #

Total comments: 4

Patch Set 7 : address comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+349 lines, -127 lines) Patch
M third_party/WebKit/LayoutTests/http/tests/inspector/bindings/bindings-multiple-frames-expected.txt View 3 chunks +2 lines, -4 lines 0 comments Download
M third_party/WebKit/LayoutTests/http/tests/inspector/bindings/contentscripts-bindings-multiple-frames-expected.txt View 2 chunks +2 lines, -4 lines 0 comments Download
M third_party/WebKit/LayoutTests/http/tests/inspector/bindings/sourcemap-bindings-multiple-frames-expected.txt View 3 chunks +2 lines, -4 lines 0 comments Download
M third_party/WebKit/LayoutTests/http/tests/inspector/bindings/suspendtarget-bindings-expected.txt View 3 chunks +3 lines, -6 lines 0 comments Download
M third_party/WebKit/LayoutTests/http/tests/inspector/resource-tree/resource-tree-frame-navigate.html View 1 1 chunk +14 lines, -16 lines 0 comments Download
M third_party/WebKit/LayoutTests/http/tests/inspector/resource-tree/resources/resource-tree-frame-navigate-iframe-before.html View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/LayoutTests/http/tests/inspector/sources/debugger/pause-in-removed-frame.html View 1 chunk +2 lines, -2 lines 0 comments Download
M third_party/WebKit/LayoutTests/inspector/sources/debugger-breakpoints/breakpoint-manager.html View 1 2 3 4 5 1 chunk +2 lines, -1 line 0 comments Download
M third_party/WebKit/LayoutTests/inspector/sources/debugger-breakpoints/breakpoint-manager.js View 1 2 3 4 5 4 chunks +18 lines, -4 lines 0 comments Download
M third_party/WebKit/LayoutTests/inspector/sources/debugger-ui/scripts-panel.html View 1 2 3 4 5 1 chunk +2 lines, -1 line 0 comments Download
M third_party/WebKit/LayoutTests/inspector/sources/debugger-ui/scripts-sorting.html View 1 2 3 4 5 1 chunk +2 lines, -1 line 0 comments Download
M third_party/WebKit/LayoutTests/inspector/sources/debugger/navigator-view.html View 1 2 3 4 5 2 chunks +3 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/devtools/BUILD.gn View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/devtools/front_end/bindings/DebuggerWorkspaceBinding.js View 1 2 3 4 5 6 2 chunks +3 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/devtools/front_end/bindings/NetworkProject.js View 1 2 3 chunks +4 lines, -80 lines 0 comments Download
A third_party/WebKit/Source/devtools/front_end/bindings/ResourceMapping.js View 1 2 3 4 5 6 1 chunk +285 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/devtools/front_end/bindings/module.json View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/devtools/front_end/main/Main.js View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
Commit queue not available (can’t edit this change).

Dependent Patchsets:

Messages

Total messages: 35 (24 generated)
lushnikov
please, take a look The ResourceBinding suggests the approach which we will use in CSS ...
4 months ago (2017-05-19 19:44:13 UTC) #1
dgozman
https://codereview.chromium.org/2893073002/diff/20001/third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js File third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js (right): https://codereview.chromium.org/2893073002/diff/20001/third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js#newcode236 third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js:236: var uiSourceCode = resourceBinding ? resourceBinding.uiSourceCodeForURL(rawLocation.url) : null; Bindings.ResourceBinding.uiSourceCodeForURL(this._target, ...
4 months ago (2017-05-19 23:51:05 UTC) #4
lushnikov
Please, take another look! https://codereview.chromium.org/2893073002/diff/20001/third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js File third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js (right): https://codereview.chromium.org/2893073002/diff/20001/third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js#newcode236 third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js:236: var uiSourceCode = resourceBinding ? ...
3 months, 2 weeks ago (2017-06-09 01:29:08 UTC) #8
dgozman
https://codereview.chromium.org/2893073002/diff/60001/third_party/WebKit/Source/devtools/BUILD.gn File third_party/WebKit/Source/devtools/BUILD.gn (right): https://codereview.chromium.org/2893073002/diff/60001/third_party/WebKit/Source/devtools/BUILD.gn#newcode73 third_party/WebKit/Source/devtools/BUILD.gn:73: "front_end/bindings/module.json", Move it back to be sorted! https://codereview.chromium.org/2893073002/diff/60001/third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js File ...
3 months, 1 week ago (2017-06-12 18:48:50 UTC) #17
lushnikov
https://codereview.chromium.org/2893073002/diff/60001/third_party/WebKit/Source/devtools/BUILD.gn File third_party/WebKit/Source/devtools/BUILD.gn (right): https://codereview.chromium.org/2893073002/diff/60001/third_party/WebKit/Source/devtools/BUILD.gn#newcode73 third_party/WebKit/Source/devtools/BUILD.gn:73: "front_end/bindings/module.json", On 2017/06/12 18:48:50, dgozman wrote: > Move it ...
3 months, 1 week ago (2017-06-12 22:05:56 UTC) #18
lushnikov
https://codereview.chromium.org/2893073002/diff/80001/third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js File third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js (right): https://codereview.chromium.org/2893073002/diff/80001/third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js#newcode232 third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js:232: uiLocation = uiLocation || Bindings.resourceBindingManager.cssLocationToUILocation(rawLocation); Rename: Bindings.ResourceBingindManager -> Bindings.ResourceBinding ...
3 months, 1 week ago (2017-06-12 23:17:53 UTC) #21
lushnikov
all done, please take another look! https://codereview.chromium.org/2893073002/diff/80001/third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js File third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js (right): https://codereview.chromium.org/2893073002/diff/80001/third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js#newcode232 third_party/WebKit/Source/devtools/front_end/bindings/CSSWorkspaceBinding.js:232: uiLocation = uiLocation ...
3 months, 1 week ago (2017-06-13 00:49:14 UTC) #25
dgozman
lgtm https://codereview.chromium.org/2893073002/diff/100001/third_party/WebKit/Source/devtools/front_end/bindings/DebuggerWorkspaceBinding.js File third_party/WebKit/Source/devtools/front_end/bindings/DebuggerWorkspaceBinding.js (right): https://codereview.chromium.org/2893073002/diff/100001/third_party/WebKit/Source/devtools/front_end/bindings/DebuggerWorkspaceBinding.js#newcode324 third_party/WebKit/Source/devtools/front_end/bindings/DebuggerWorkspaceBinding.js:324: rawLocation || Bindings.resourceMapping.uiLocationToJSLocation(uiSourceCode, lineNumber, columnNumber); Call this before ...
3 months, 1 week ago (2017-06-13 00:58:41 UTC) #28
lushnikov
Thanks, all done! https://codereview.chromium.org/2893073002/diff/100001/third_party/WebKit/Source/devtools/front_end/bindings/DebuggerWorkspaceBinding.js File third_party/WebKit/Source/devtools/front_end/bindings/DebuggerWorkspaceBinding.js (right): https://codereview.chromium.org/2893073002/diff/100001/third_party/WebKit/Source/devtools/front_end/bindings/DebuggerWorkspaceBinding.js#newcode324 third_party/WebKit/Source/devtools/front_end/bindings/DebuggerWorkspaceBinding.js:324: rawLocation || Bindings.resourceMapping.uiLocationToJSLocation(uiSourceCode, lineNumber, columnNumber); On ...
3 months, 1 week ago (2017-06-13 01:07:04 UTC) #29
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2893073002/120001
3 months, 1 week ago (2017-06-13 01:07:38 UTC) #32
commit-bot: I haz the power
3 months, 1 week ago (2017-06-13 03:37:23 UTC) #35
Message was sent while issue was closed.
Committed patchset #7 (id:120001) as
https://chromium.googlesource.com/chromium/src/+/19a7ba263cc0eff46ac4752bbd04...
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld b40b6558b