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

Unified Diff: chrome/browser/devtools/devtools_protocol.cc

Issue 2809733002: Revert of add a new set of commands to resize and position windows (Closed)
Patch Set: Created 3 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
« no previous file with comments | « chrome/browser/devtools/devtools_protocol.h ('k') | chrome/browser/devtools/devtools_sanity_browsertest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/devtools/devtools_protocol.cc
diff --git a/chrome/browser/devtools/devtools_protocol.cc b/chrome/browser/devtools/devtools_protocol.cc
index 8581d8b6279fd050ad9be9801d33dbe60bfb9ee1..a22811053180c073bdcfd1f65072d176f448765c 100644
--- a/chrome/browser/devtools/devtools_protocol.cc
+++ b/chrome/browser/devtools/devtools_protocol.cc
@@ -19,7 +19,9 @@
const char kResultParam[] = "result";
// JSON RPC 2.0 spec: http://www.jsonrpc.org/specification#error_object
-enum Error { kErrorInvalidParams = -32602, kErrorServerError = -32000 };
+enum Error {
+ kErrorInvalidParams = -32602
+};
} // namespace
@@ -44,26 +46,12 @@
DevToolsProtocol::CreateInvalidParamsResponse(int command_id,
const std::string& param) {
std::unique_ptr<base::DictionaryValue> response(new base::DictionaryValue());
- response->SetInteger(kIdParam, command_id);
base::DictionaryValue* error_object = new base::DictionaryValue();
response->Set(kErrorParam, error_object);
error_object->SetInteger(kErrorCodeParam, kErrorInvalidParams);
error_object->SetString(kErrorMessageParam,
base::StringPrintf("Missing or invalid '%s' parameter", param.c_str()));
- return response;
-}
-
-// static
-std::unique_ptr<base::DictionaryValue> DevToolsProtocol::CreateErrorResponse(
- int command_id,
- const std::string& error_message) {
- std::unique_ptr<base::DictionaryValue> response(new base::DictionaryValue());
- response->SetInteger(kIdParam, command_id);
- base::DictionaryValue* error_object = new base::DictionaryValue();
- response->Set(kErrorParam, error_object);
- error_object->SetInteger(kErrorCodeParam, kErrorServerError);
- error_object->SetString(kErrorMessageParam, error_message);
return response;
}
« no previous file with comments | « chrome/browser/devtools/devtools_protocol.h ('k') | chrome/browser/devtools/devtools_sanity_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698