Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(121)

Unified Diff: third_party/WebKit/Source/devtools/front_end/bindings/CompilerScriptMapping.js

Issue 1699183003: [DevTools] Don't load sourcemap for blackboxed scripts (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@add-source-map-support-v3
Patch Set: Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/devtools/front_end/bindings/CompilerScriptMapping.js
diff --git a/third_party/WebKit/Source/devtools/front_end/bindings/CompilerScriptMapping.js b/third_party/WebKit/Source/devtools/front_end/bindings/CompilerScriptMapping.js
index e116c9f7670c2fb67f363e424df174b4cc633994..32b1832310be1e6bd0f4d68625279fab0b7c0ea8 100644
--- a/third_party/WebKit/Source/devtools/front_end/bindings/CompilerScriptMapping.js
+++ b/third_party/WebKit/Source/devtools/front_end/bindings/CompilerScriptMapping.js
@@ -166,6 +166,20 @@ WebInspector.CompilerScriptMapping.prototype = {
},
/**
+ * @param {!WebInspector.Script} script
+ */
+ maybeLoadSourceMap: function(script)
+ {
+ if (!script.sourceMapURL)
+ return;
+ if (this._pendingSourceMapLoadingCallbacks[script.sourceMapURL])
+ return;
+ if (this._sourceMapForScriptId[script.scriptId])
+ return;
+ this._processScript(script);
+ },
+
+ /**
* @param {!WebInspector.Event} event
*/
_sourceMapURLAdded: function(event)
@@ -181,6 +195,8 @@ WebInspector.CompilerScriptMapping.prototype = {
*/
_processScript: function(script)
{
+ if (WebInspector.blackboxManager.isBlackboxedURL(script.sourceURL, script.isContentScript()))
+ return;
// Create stub UISourceCode for the time source mapping is being loaded.
var stubUISourceCode = this._stubProject.addContentProvider(script.sourceURL, new WebInspector.StaticContentProvider(WebInspector.resourceTypes.Script, "\n\n\n\n\n// Please wait a bit.\n// Compiled script is not shown while source map is being loaded!", script.sourceURL));
this._stubUISourceCodes.set(script.scriptId, stubUISourceCode);

Powered by Google App Engine
This is Rietveld 408576698