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

Unified Diff: sync/protocol/proto_value_conversions.cc

Issue 218623014: [Sync] Add context proto and directory support (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Update protos Created 6 years, 9 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 | « no previous file | sync/protocol/sync.proto » ('j') | sync/protocol/sync.proto » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sync/protocol/proto_value_conversions.cc
diff --git a/sync/protocol/proto_value_conversions.cc b/sync/protocol/proto_value_conversions.cc
index 496a35d26993136782d24ff345ccfc74012ffefe..83140faa9a84f70322bec04cbe88a27c58b90ddc 100644
--- a/sync/protocol/proto_value_conversions.cc
+++ b/sync/protocol/proto_value_conversions.cc
@@ -867,6 +867,15 @@ base::DictionaryValue* DataTypeProgressMarkerToValue(
return value;
}
+base::DictionaryValue* DataTypeContextToValue(
+ const sync_pb::DataTypeContext& proto) {
+ base::DictionaryValue* value = new base::DictionaryValue();
+ SET_INT32(type);
rlarocque 2014/04/03 01:08:06 off-topic: We should add a SET_TYPE macro. I'm ti
Nicolas Zea 2014/04/03 21:01:11 SGTM
+ SET_STR(context);
+ SET_INT64(version);
+ return value;
+}
+
base::DictionaryValue* GetUpdatesCallerInfoToValue(
const sync_pb::GetUpdatesCallerInfo& proto) {
base::DictionaryValue* value = new base::DictionaryValue();
@@ -886,6 +895,7 @@ base::DictionaryValue* GetUpdatesMessageToValue(
SET_BOOL(need_encryption_key);
SET_BOOL(create_mobile_bookmarks_folder);
SET_ENUM(get_updates_origin, GetUpdatesOriginString);
+ SET_REP(client_contexts, DataTypeContextToValue);
return value;
}
@@ -924,6 +934,7 @@ base::DictionaryValue* GetUpdatesResponseToValue(
SyncEntitiesToValue(proto.entries(), include_specifics));
SET_INT64(changes_remaining);
SET_REP(new_progress_marker, DataTypeProgressMarkerToValue);
+ SET_REP(context_mutations, DataTypeContextToValue);
return value;
}
« no previous file with comments | « no previous file | sync/protocol/sync.proto » ('j') | sync/protocol/sync.proto » ('J')

Powered by Google App Engine
This is Rietveld 408576698