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

Unified Diff: Source/core/inspector/InjectedScript.cpp

Issue 19064004: Support re-reading scope variables in protocol and on backed. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: clean Created 7 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/core/inspector/InjectedScript.cpp
diff --git a/Source/core/inspector/InjectedScript.cpp b/Source/core/inspector/InjectedScript.cpp
index 43422c81e7ef91e51949836cbe5a242952142a5a..c0b56701bb7b59068359216ef52b055343221347 100644
--- a/Source/core/inspector/InjectedScript.cpp
+++ b/Source/core/inspector/InjectedScript.cpp
@@ -142,6 +142,22 @@ void InjectedScript::setVariableValue(ErrorString* errorString, const ScriptValu
// Normal return.
}
+void InjectedScript::getCallFrameScopes(ErrorString* errorString, const ScriptValue& callFrames, const String& callFrameId, RefPtr<TypeBuilder::Array<TypeBuilder::Debugger::Scope> >* result)
+{
+ ScriptFunctionCall function(injectedScriptObject(), "getCallFrameScopes");
+ function.appendArgument(callFrames);
+ function.appendArgument(callFrameId);
+ RefPtr<JSONValue> resultValue;
+ makeCall(function, &resultValue);
+ if (!resultValue || resultValue->type() != JSONValue::TypeArray) {
+ if (!resultValue->asString(errorString))
+ *errorString = "Internal error";
+ return;
+ }
+ *result = TypeBuilder::Array<TypeBuilder::Debugger::Scope>::runtimeCast(resultValue);
+}
+
+
void InjectedScript::getFunctionDetails(ErrorString* errorString, const String& functionId, RefPtr<FunctionDetails>* result)
{
ScriptFunctionCall function(injectedScriptObject(), "getFunctionDetails");

Powered by Google App Engine
This is Rietveld 408576698