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

Unified Diff: third_party/WebKit/Source/devtools/front_end/sources/ScopeChainSidebarPane.js

Issue 1884213003: DevTools: teach SourceMapNamesResolver to resolve "this" object (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@ids
Patch Set: fix tesst Created 4 years, 8 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/ScopeChainSidebarPane.js
diff --git a/third_party/WebKit/Source/devtools/front_end/sources/ScopeChainSidebarPane.js b/third_party/WebKit/Source/devtools/front_end/sources/ScopeChainSidebarPane.js
index ac4a2ef80ec9ced2537829cf104818daa7c9aab2..53a773a127021a915ef84758625a2f0f7b4ebba8 100644
--- a/third_party/WebKit/Source/devtools/front_end/sources/ScopeChainSidebarPane.js
+++ b/third_party/WebKit/Source/devtools/front_end/sources/ScopeChainSidebarPane.js
@@ -42,6 +42,16 @@ WebInspector.ScopeChainSidebarPane.prototype = {
*/
update: function(callFrame)
{
+ WebInspector.SourceMapNamesResolver.resolveThisObject(callFrame)
+ .then(this._innerUpdate.bind(this, callFrame));
+ },
+
+ /**
+ * @param {?WebInspector.DebuggerModel.CallFrame} callFrame
+ * @param {?WebInspector.RemoteObject} thisObject
+ */
+ _innerUpdate: function(callFrame, thisObject)
+ {
this.element.removeChildren();
if (!callFrame) {
@@ -65,7 +75,6 @@ WebInspector.ScopeChainSidebarPane.prototype = {
foundLocalScope = true;
title = WebInspector.UIString("Local");
emptyPlaceholder = WebInspector.UIString("No Variables");
- var thisObject = callFrame.thisObject();
if (thisObject)
extraProperties.push(new WebInspector.RemoteObjectProperty("this", thisObject));
if (i == 0) {
@@ -122,7 +131,10 @@ WebInspector.ScopeChainSidebarPane.prototype = {
section.element.classList.add("scope-chain-sidebar-pane-section");
this.element.appendChild(section.element);
}
+ this._sidebarPaneUpdatedForTest();
},
+ _sidebarPaneUpdatedForTest: function() { },
+
__proto__: WebInspector.SidebarPane.prototype
}

Powered by Google App Engine
This is Rietveld 408576698