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

Unified Diff: third_party/WebKit/Source/devtools/front_end/sources/JavaScriptSourceFrame.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/sources/JavaScriptSourceFrame.js
diff --git a/third_party/WebKit/Source/devtools/front_end/sources/JavaScriptSourceFrame.js b/third_party/WebKit/Source/devtools/front_end/sources/JavaScriptSourceFrame.js
index 4841b8bd2552e87c53e75ba3fa6bc9ab2cdc627d..6a87b32ded18137615e36ba835db963b0260ec48 100644
--- a/third_party/WebKit/Source/devtools/front_end/sources/JavaScriptSourceFrame.js
+++ b/third_party/WebKit/Source/devtools/front_end/sources/JavaScriptSourceFrame.js
@@ -162,6 +162,10 @@ WebInspector.JavaScriptSourceFrame.prototype = {
this._blackboxInfobar = infobar;
infobar.createDetailsRowMessage(WebInspector.UIString("Debugger will skip stepping through this script, and will not stop on exceptions"));
+
+ var scriptFile = this._scriptFileForTarget.valuesArray()[0];
+ if (scriptFile.hasSourceMapURL())
+ infobar.createDetailsRowMessage(WebInspector.UIString("SourceMap will be ignored for this file."));
paulirish 2016/02/22 18:47:41 "Source map found, but ignored for blackboxed file
infobar.createDetailsRowMessage();
infobar.createDetailsRowMessage(WebInspector.UIString("Possible ways to cancel this behavior are:"));
@@ -348,6 +352,8 @@ WebInspector.JavaScriptSourceFrame.prototype = {
if (this.uiSourceCode().project().type() === WebInspector.projectTypes.Network && WebInspector.moduleSetting("jsSourceMapsEnabled").get()) {
if (this._scriptFileForTarget.size) {
var scriptFile = this._scriptFileForTarget.valuesArray()[0];
+ if (scriptFile.isBlackboxed())
+ return;
var addSourceMapURLLabel = WebInspector.UIString.capitalize("Add ^source ^map\u2026");
contextMenu.appendItem(addSourceMapURLLabel, addSourceMapURL.bind(null, scriptFile));
contextMenu.appendSeparator();

Powered by Google App Engine
This is Rietveld 408576698