| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/sync/glue/sync_backend_host.h" | 5 #include "chrome/browser/sync/glue/sync_backend_host.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <map> | 8 #include <map> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 1376 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1387 void SyncBackendHost::Core::DoRetryConfiguration( | 1387 void SyncBackendHost::Core::DoRetryConfiguration( |
| 1388 const base::Closure& retry_callback) { | 1388 const base::Closure& retry_callback) { |
| 1389 DCHECK_EQ(base::MessageLoop::current(), sync_loop_); | 1389 DCHECK_EQ(base::MessageLoop::current(), sync_loop_); |
| 1390 host_.Call(FROM_HERE, | 1390 host_.Call(FROM_HERE, |
| 1391 &SyncBackendHost::RetryConfigurationOnFrontendLoop, | 1391 &SyncBackendHost::RetryConfigurationOnFrontendLoop, |
| 1392 retry_callback); | 1392 retry_callback); |
| 1393 } | 1393 } |
| 1394 | 1394 |
| 1395 void SyncBackendHost::Core::DeleteSyncDataFolder() { | 1395 void SyncBackendHost::Core::DeleteSyncDataFolder() { |
| 1396 DCHECK_EQ(base::MessageLoop::current(), sync_loop_); | 1396 DCHECK_EQ(base::MessageLoop::current(), sync_loop_); |
| 1397 if (file_util::DirectoryExists(sync_data_folder_path_)) { | 1397 if (base::DirectoryExists(sync_data_folder_path_)) { |
| 1398 if (!base::Delete(sync_data_folder_path_, true)) | 1398 if (!base::Delete(sync_data_folder_path_, true)) |
| 1399 SLOG(DFATAL) << "Could not delete the Sync Data folder."; | 1399 SLOG(DFATAL) << "Could not delete the Sync Data folder."; |
| 1400 } | 1400 } |
| 1401 } | 1401 } |
| 1402 | 1402 |
| 1403 void SyncBackendHost::Core::StartSavingChanges() { | 1403 void SyncBackendHost::Core::StartSavingChanges() { |
| 1404 // We may already be shut down. | 1404 // We may already be shut down. |
| 1405 if (!sync_loop_) | 1405 if (!sync_loop_) |
| 1406 return; | 1406 return; |
| 1407 DCHECK_EQ(base::MessageLoop::current(), sync_loop_); | 1407 DCHECK_EQ(base::MessageLoop::current(), sync_loop_); |
| (...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1627 DVLOG(1) << "Connection status changed: " | 1627 DVLOG(1) << "Connection status changed: " |
| 1628 << syncer::ConnectionStatusToString(status); | 1628 << syncer::ConnectionStatusToString(status); |
| 1629 frontend_->OnConnectionStatusChange(status); | 1629 frontend_->OnConnectionStatusChange(status); |
| 1630 } | 1630 } |
| 1631 | 1631 |
| 1632 #undef SDVLOG | 1632 #undef SDVLOG |
| 1633 | 1633 |
| 1634 #undef SLOG | 1634 #undef SLOG |
| 1635 | 1635 |
| 1636 } // namespace browser_sync | 1636 } // namespace browser_sync |
| OLD | NEW |