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

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

Issue 1249013002: DevTools: simplify setScriptSource and restartFrame return values (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Addressed dgozman's comments Created 5 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
« no previous file with comments | « Source/core/inspector/InjectedScript.h ('k') | Source/core/inspector/InjectedScriptSource.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/inspector/InjectedScript.cpp
diff --git a/Source/core/inspector/InjectedScript.cpp b/Source/core/inspector/InjectedScript.cpp
index 2420934a68ee8c2e7e252c58be345a5cfade17b5..c6c60548a54dcdbbea5484f9db9625c0ce8680f7 100644
--- a/Source/core/inspector/InjectedScript.cpp
+++ b/Source/core/inspector/InjectedScript.cpp
@@ -169,7 +169,7 @@ void InjectedScript::evaluateOnCallFrame(ErrorString* errorString, v8::Local<v8:
makeEvalCall(errorString, function, result, wasThrown, exceptionDetails);
}
-void InjectedScript::restartFrame(ErrorString* errorString, v8::Local<v8::Object> callFrames, const String& callFrameId, RefPtr<JSONObject>* result)
+void InjectedScript::restartFrame(ErrorString* errorString, v8::Local<v8::Object> callFrames, const String& callFrameId)
{
ScriptFunctionCall function(injectedScriptObject(), "restartFrame");
function.appendArgument(callFrames);
@@ -179,12 +179,11 @@ void InjectedScript::restartFrame(ErrorString* errorString, v8::Local<v8::Object
if (resultValue) {
if (resultValue->type() == JSONValue::TypeString) {
resultValue->asString(errorString);
- return;
- }
- if (resultValue->type() == JSONValue::TypeObject) {
- *result = resultValue->asObject();
- return;
+ } else {
+ bool value;
+ ASSERT_UNUSED(value, resultValue->asBoolean(&value) && value);
}
+ return;
}
*errorString = "Internal error";
}
« no previous file with comments | « Source/core/inspector/InjectedScript.h ('k') | Source/core/inspector/InjectedScriptSource.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698