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

Unified Diff: Source/devtools/front_end/sdk/Script.js

Issue 373743003: DevTools: Add support for adding source map to a script from the DevTools window. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebaselined Created 6 years, 5 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: Source/devtools/front_end/sdk/Script.js
diff --git a/Source/devtools/front_end/sdk/Script.js b/Source/devtools/front_end/sdk/Script.js
index de30f4921b2351280d26571b860abdf97c070ae7..a646a7ded254f3dcc49596e80ce00d95ac4950b6 100644
--- a/Source/devtools/front_end/sdk/Script.js
+++ b/Source/devtools/front_end/sdk/Script.js
@@ -58,6 +58,7 @@ WebInspector.Script = function(target, scriptId, sourceURL, startLine, startColu
WebInspector.Script.Events = {
ScriptEdited: "ScriptEdited",
+ SourceMapURLAdded: "SourceMapURLAdded",
}
WebInspector.Script.snippetSourceURLPrefix = "snippets:///";
@@ -213,6 +214,17 @@ WebInspector.Script.prototype = {
},
/**
+ * @param {string} sourceMapURL
+ */
+ addSourceMapURL: function(sourceMapURL)
+ {
+ if (this.sourceMapURL)
+ return;
+ this.sourceMapURL = sourceMapURL;
+ this.dispatchEventToListeners(WebInspector.Script.Events.SourceMapURLAdded, this.sourceMapURL);
+ },
+
+ /**
* @return {boolean}
*/
isAnonymousScript: function()
« no previous file with comments | « Source/devtools/front_end/sdk/ResourceScriptMapping.js ('k') | Source/devtools/front_end/sdk/UISourceCode.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698