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

Unified Diff: chrome/browser/sync/protocol/proto_value_conversions.cc

Issue 7649006: more changes (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix another typo Created 9 years, 4 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: chrome/browser/sync/protocol/proto_value_conversions.cc
diff --git a/chrome/browser/sync/protocol/proto_value_conversions.cc b/chrome/browser/sync/protocol/proto_value_conversions.cc
index 753f568df8baf5b0b62daff00a0f16dc13916b92..568919913d9aa95b5056188a46808fe7f3612840 100644
--- a/chrome/browser/sync/protocol/proto_value_conversions.cc
+++ b/chrome/browser/sync/protocol/proto_value_conversions.cc
@@ -33,7 +33,7 @@ namespace {
// Basic Type -> Value functions.
StringValue* MakeInt64Value(int64 x) {
- return Value::CreateStringValue(base::Int64ToString(x));
+ return base::StringValue::New(base::Int64ToString(x));
}
// TODO(akalin): Perhaps make JSONWriter support BinaryValue and use
@@ -43,13 +43,13 @@ StringValue* MakeBytesValue(const std::string& bytes) {
if (!base::Base64Encode(bytes, &bytes_base64)) {
NOTREACHED();
}
- return Value::CreateStringValue(bytes_base64);
+ return base::StringValue::New(bytes_base64);
}
// T is the enum type.
template <class T>
StringValue* MakeEnumValue(T t, const char* (*converter_fn)(T)) {
- return Value::CreateStringValue(converter_fn(t));
+ return base::StringValue::New(converter_fn(t));
}
// T is the field type, F is either RepeatedField or RepeatedPtrField,
@@ -74,13 +74,13 @@ ListValue* MakeRepeatedValue(const F& fields, V* (*converter_fn)(T)) {
#define SET_ENUM(field, fn) \
value->Set(#field, MakeEnumValue(proto.field(), fn))
-#define SET_BOOL(field) SET(field, Value::CreateBooleanValue)
+#define SET_BOOL(field) SET(field, base::BooleanValue::New)
#define SET_BYTES(field) SET(field, MakeBytesValue)
#define SET_INT32(field) SET(field, MakeInt64Value)
#define SET_INT32_REP(field) SET_REP(field, MakeInt64Value)
#define SET_INT64(field) SET(field, MakeInt64Value)
#define SET_INT64_REP(field) SET_REP(field, MakeInt64Value)
-#define SET_STR(field) SET(field, Value::CreateStringValue)
+#define SET_STR(field) SET(field, base::StringValue::New)
#define SET_EXTENSION(ns, field, fn) \
do { \
« no previous file with comments | « chrome/browser/sync/profile_sync_service_unittest.cc ('k') | chrome/browser/sync/sync_js_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698