Index: components/sync/test/fake_sync_encryption_handler.cc |
diff --git a/sync/test/fake_sync_encryption_handler.cc b/components/sync/test/fake_sync_encryption_handler.cc |
similarity index 80% |
rename from sync/test/fake_sync_encryption_handler.cc |
rename to components/sync/test/fake_sync_encryption_handler.cc |
index d524e60b68c0655b94c5ca64c2bb45968675b1f0..66bf7fb89938bcd0e6898be1f48421cbebebfcad 100644 |
--- a/sync/test/fake_sync_encryption_handler.cc |
+++ b/components/sync/test/fake_sync_encryption_handler.cc |
@@ -2,10 +2,10 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
-#include "sync/test/fake_sync_encryption_handler.h" |
+#include "components/sync/test/fake_sync_encryption_handler.h" |
-#include "sync/protocol/nigori_specifics.pb.h" |
-#include "sync/syncable/nigori_util.h" |
+#include "components/sync/protocol/nigori_specifics.pb.h" |
+#include "components/sync/syncable/nigori_util.h" |
namespace syncer { |
@@ -13,8 +13,7 @@ FakeSyncEncryptionHandler::FakeSyncEncryptionHandler() |
: encrypted_types_(SensitiveTypes()), |
encrypt_everything_(false), |
passphrase_type_(IMPLICIT_PASSPHRASE), |
- cryptographer_(&encryptor_) { |
-} |
+ cryptographer_(&encryptor_) {} |
FakeSyncEncryptionHandler::~FakeSyncEncryptionHandler() {} |
void FakeSyncEncryptionHandler::Init() { |
@@ -41,14 +40,13 @@ void FakeSyncEncryptionHandler::ApplyNigoriUpdate( |
DVLOG(1) << "OnPassPhraseRequired Sent"; |
sync_pb::EncryptedData pending_keys = cryptographer_.GetPendingKeys(); |
FOR_EACH_OBSERVER(SyncEncryptionHandler::Observer, observers_, |
- OnPassphraseRequired(REASON_DECRYPTION, |
- pending_keys)); |
+ OnPassphraseRequired(REASON_DECRYPTION, pending_keys)); |
} else if (!cryptographer_.is_ready()) { |
DVLOG(1) << "OnPassphraseRequired sent because cryptographer is not " |
<< "ready"; |
- FOR_EACH_OBSERVER(SyncEncryptionHandler::Observer, observers_, |
- OnPassphraseRequired(REASON_ENCRYPTION, |
- sync_pb::EncryptedData())); |
+ FOR_EACH_OBSERVER( |
+ SyncEncryptionHandler::Observer, observers_, |
+ OnPassphraseRequired(REASON_ENCRYPTION, sync_pb::EncryptedData())); |
} |
} |
@@ -56,8 +54,7 @@ void FakeSyncEncryptionHandler::UpdateNigoriFromEncryptedTypes( |
sync_pb::NigoriSpecifics* nigori, |
syncable::BaseTransaction* const trans) const { |
syncable::UpdateNigoriFromEncryptedTypes(encrypted_types_, |
- encrypt_everything_, |
- nigori); |
+ encrypt_everything_, nigori); |
} |
bool FakeSyncEncryptionHandler::NeedKeystoreKey( |
@@ -70,16 +67,15 @@ bool FakeSyncEncryptionHandler::SetKeystoreKeys( |
syncable::BaseTransaction* const trans) { |
if (keys.size() == 0) |
return false; |
- std::string new_key = keys.Get(keys.size()-1); |
+ std::string new_key = keys.Get(keys.size() - 1); |
if (new_key.empty()) |
return false; |
keystore_key_ = new_key; |
- |
DVLOG(1) << "Keystore bootstrap token updated."; |
- FOR_EACH_OBSERVER(SyncEncryptionHandler::Observer, observers_, |
- OnBootstrapTokenUpdated(keystore_key_, |
- KEYSTORE_BOOTSTRAP_TOKEN)); |
+ FOR_EACH_OBSERVER( |
+ SyncEncryptionHandler::Observer, observers_, |
+ OnBootstrapTokenUpdated(keystore_key_, KEYSTORE_BOOTSTRAP_TOKEN)); |
return true; |
} |