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

Unified Diff: Source/devtools/front_end/Linkifier.js

Issue 205563007: CPUProfiler: convert Flame Chart into Icicle Chart (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: the function was moved to Script.js Created 6 years, 9 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/Linkifier.js
diff --git a/Source/devtools/front_end/Linkifier.js b/Source/devtools/front_end/Linkifier.js
index fb7f26635d10bd4dc88040da23faa050013a7bc5..2840b6158941a0d9a6e19f28039e77db6e4e2463 100644
--- a/Source/devtools/front_end/Linkifier.js
+++ b/Source/devtools/front_end/Linkifier.js
@@ -276,3 +276,17 @@ WebInspector.Linkifier.LinkHandler.prototype = {
*/
handleLink: function(url, lineNumber) {}
}
+
+/**
+ * @param {string} scriptId
+ * @param {number} lineNumber
+ * @param {number=} columnNumber
+ */
+WebInspector.Linkifier.liveLocationText = function(scriptId, lineNumber, columnNumber)
+{
+ var script = WebInspector.debuggerModel.scriptForId(scriptId);
+ if (!script)
+ return "";
+ var uiLocation = script.rawLocationToUILocation(lineNumber, columnNumber);
+ return uiLocation.linkText();
+}

Powered by Google App Engine
This is Rietveld 408576698