| 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/profile_sync_service.h" | 5 #include "chrome/browser/sync/profile_sync_service.h" |
| 6 | 6 |
| 7 #include <cstddef> | 7 #include <cstddef> |
| 8 #include <map> | 8 #include <map> |
| 9 #include <set> | 9 #include <set> |
| 10 #include <utility> | 10 #include <utility> |
| (...skipping 1323 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1334 if (!startup_controller_.auto_start_enabled()) | 1334 if (!startup_controller_.auto_start_enabled()) |
| 1335 SigninManagerFactory::GetForProfile(profile_)->SignOut(); | 1335 SigninManagerFactory::GetForProfile(profile_)->SignOut(); |
| 1336 #endif | 1336 #endif |
| 1337 break; | 1337 break; |
| 1338 case syncer::STOP_SYNC_FOR_DISABLED_ACCOUNT: | 1338 case syncer::STOP_SYNC_FOR_DISABLED_ACCOUNT: |
| 1339 // Sync disabled by domain admin. we should stop syncing until next | 1339 // Sync disabled by domain admin. we should stop syncing until next |
| 1340 // restart. | 1340 // restart. |
| 1341 sync_disabled_by_admin_ = true; | 1341 sync_disabled_by_admin_ = true; |
| 1342 ShutdownImpl(browser_sync::SyncBackendHost::DISABLE_AND_CLAIM_THREAD); | 1342 ShutdownImpl(browser_sync::SyncBackendHost::DISABLE_AND_CLAIM_THREAD); |
| 1343 break; | 1343 break; |
| 1344 case syncer::DISABLE_SYNC_AND_ROLLBACK: |
| 1345 NOTIMPLEMENTED(); |
| 1346 break; |
| 1344 default: | 1347 default: |
| 1345 NOTREACHED(); | 1348 NOTREACHED(); |
| 1346 } | 1349 } |
| 1347 NotifyObservers(); | 1350 NotifyObservers(); |
| 1348 } | 1351 } |
| 1349 | 1352 |
| 1350 void ProfileSyncService::OnConfigureDone( | 1353 void ProfileSyncService::OnConfigureDone( |
| 1351 const browser_sync::DataTypeManager::ConfigureResult& result) { | 1354 const browser_sync::DataTypeManager::ConfigureResult& result) { |
| 1352 // We should have cleared our cached passphrase before we get here (in | 1355 // We should have cleared our cached passphrase before we get here (in |
| 1353 // OnBackendInitialized()). | 1356 // OnBackendInitialized()). |
| (...skipping 1000 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2354 status.last_get_token_error = last_get_token_error_; | 2357 status.last_get_token_error = last_get_token_error_; |
| 2355 if (request_access_token_retry_timer_.IsRunning()) | 2358 if (request_access_token_retry_timer_.IsRunning()) |
| 2356 status.next_token_request_time = next_token_request_time_; | 2359 status.next_token_request_time = next_token_request_time_; |
| 2357 return status; | 2360 return status; |
| 2358 } | 2361 } |
| 2359 | 2362 |
| 2360 void ProfileSyncService::OverrideNetworkResourcesForTest( | 2363 void ProfileSyncService::OverrideNetworkResourcesForTest( |
| 2361 scoped_ptr<syncer::NetworkResources> network_resources) { | 2364 scoped_ptr<syncer::NetworkResources> network_resources) { |
| 2362 network_resources_ = network_resources.Pass(); | 2365 network_resources_ = network_resources.Pass(); |
| 2363 } | 2366 } |
| OLD | NEW |