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

Unified Diff: components/sync/protocol/proto_value_conversions.cc

Issue 2130453004: [Sync] Move //sync to //components/sync. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 4 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: components/sync/protocol/proto_value_conversions.cc
diff --git a/sync/protocol/proto_value_conversions.cc b/components/sync/protocol/proto_value_conversions.cc
similarity index 93%
rename from sync/protocol/proto_value_conversions.cc
rename to components/sync/protocol/proto_value_conversions.cc
index d296e588221b3ea22aa2077f5aac36fc3f906fcb..5ad15c4de04abe18ea98a82ee488b91ac570eaa2 100644
--- a/sync/protocol/proto_value_conversions.cc
+++ b/components/sync/protocol/proto_value_conversions.cc
@@ -4,7 +4,7 @@
// Keep this file in sync with the .proto files in this directory.
-#include "sync/protocol/proto_value_conversions.h"
+#include "components/sync/protocol/proto_value_conversions.h"
#include <stdint.h>
@@ -18,34 +18,34 @@
#include "base/strings/string_number_conversions.h"
#include "base/time/time.h"
#include "base/values.h"
-#include "sync/internal_api/public/base/unique_position.h"
-#include "sync/protocol/app_list_specifics.pb.h"
-#include "sync/protocol/app_notification_specifics.pb.h"
-#include "sync/protocol/app_setting_specifics.pb.h"
-#include "sync/protocol/app_specifics.pb.h"
-#include "sync/protocol/arc_package_specifics.pb.h"
-#include "sync/protocol/autofill_specifics.pb.h"
-#include "sync/protocol/bookmark_specifics.pb.h"
-#include "sync/protocol/dictionary_specifics.pb.h"
-#include "sync/protocol/encryption.pb.h"
-#include "sync/protocol/experiments_specifics.pb.h"
-#include "sync/protocol/extension_setting_specifics.pb.h"
-#include "sync/protocol/extension_specifics.pb.h"
-#include "sync/protocol/favicon_image_specifics.pb.h"
-#include "sync/protocol/favicon_tracking_specifics.pb.h"
-#include "sync/protocol/history_delete_directive_specifics.pb.h"
-#include "sync/protocol/nigori_specifics.pb.h"
-#include "sync/protocol/password_specifics.pb.h"
-#include "sync/protocol/preference_specifics.pb.h"
-#include "sync/protocol/priority_preference_specifics.pb.h"
-#include "sync/protocol/proto_enum_conversions.h"
-#include "sync/protocol/search_engine_specifics.pb.h"
-#include "sync/protocol/session_specifics.pb.h"
-#include "sync/protocol/sync.pb.h"
-#include "sync/protocol/theme_specifics.pb.h"
-#include "sync/protocol/typed_url_specifics.pb.h"
-#include "sync/protocol/unique_position.pb.h"
-#include "sync/util/time.h"
+#include "components/sync/base/time.h"
+#include "components/sync/base/unique_position.h"
+#include "components/sync/protocol/app_list_specifics.pb.h"
+#include "components/sync/protocol/app_notification_specifics.pb.h"
+#include "components/sync/protocol/app_setting_specifics.pb.h"
+#include "components/sync/protocol/app_specifics.pb.h"
+#include "components/sync/protocol/arc_package_specifics.pb.h"
+#include "components/sync/protocol/autofill_specifics.pb.h"
+#include "components/sync/protocol/bookmark_specifics.pb.h"
+#include "components/sync/protocol/dictionary_specifics.pb.h"
+#include "components/sync/protocol/encryption.pb.h"
+#include "components/sync/protocol/experiments_specifics.pb.h"
+#include "components/sync/protocol/extension_setting_specifics.pb.h"
+#include "components/sync/protocol/extension_specifics.pb.h"
+#include "components/sync/protocol/favicon_image_specifics.pb.h"
+#include "components/sync/protocol/favicon_tracking_specifics.pb.h"
+#include "components/sync/protocol/history_delete_directive_specifics.pb.h"
+#include "components/sync/protocol/nigori_specifics.pb.h"
+#include "components/sync/protocol/password_specifics.pb.h"
+#include "components/sync/protocol/preference_specifics.pb.h"
+#include "components/sync/protocol/priority_preference_specifics.pb.h"
+#include "components/sync/protocol/proto_enum_conversions.h"
+#include "components/sync/protocol/search_engine_specifics.pb.h"
+#include "components/sync/protocol/session_specifics.pb.h"
+#include "components/sync/protocol/sync.pb.h"
+#include "components/sync/protocol/theme_specifics.pb.h"
+#include "components/sync/protocol/typed_url_specifics.pb.h"
+#include "components/sync/protocol/unique_position.pb.h"
namespace syncer {
@@ -110,21 +110,18 @@ std::unique_ptr<base::ListValue> MakeRepeatedValue(const F& fields,
google::protobuf::RepeatedPtrField<std::string>, \
std::unique_ptr<base::StringValue>>(proto.field(), \
MakeStringValue))
-#define SET_EXPERIMENT_ENABLED_FIELD(field) \
- do { \
- if (proto.has_##field() && \
- proto.field().has_enabled()) { \
- value->Set(#field, \
- new base::FundamentalValue( \
- proto.field().enabled())); \
- } \
+#define SET_EXPERIMENT_ENABLED_FIELD(field) \
+ do { \
+ if (proto.has_##field() && proto.field().has_enabled()) { \
+ value->Set(#field, new base::FundamentalValue(proto.field().enabled())); \
+ } \
} while (0)
-#define SET_FIELD(field, fn) \
- do { \
- if (specifics.has_##field()) { \
- value->Set(#field, fn(specifics.field())); \
- } \
+#define SET_FIELD(field, fn) \
+ do { \
+ if (specifics.has_##field()) { \
+ value->Set(#field, fn(specifics.field())); \
+ } \
} while (0)
// If you add another macro, don't forget to add an #undef at the end
@@ -387,8 +384,7 @@ std::unique_ptr<base::DictionaryValue> AutofillWalletSpecificsToValue(
value->Set("masked_card",
WalletMaskedCreditCardToValue(proto.masked_card()));
} else if (proto.type() == sync_pb::AutofillWalletSpecifics::POSTAL_ADDRESS) {
- value->Set("address",
- WalletPostalAddressToValue(proto.address()));
+ value->Set("address", WalletPostalAddressToValue(proto.address()));
}
return value;
}
« no previous file with comments | « components/sync/protocol/proto_value_conversions.h ('k') | components/sync/protocol/proto_value_conversions_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698