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

Side by Side Diff: chrome/browser/sync/credential_cache_service_win.cc

Issue 10928017: Moving google_apis and GaiaClient to src/google_apis. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge to head Created 8 years, 3 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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/credential_cache_service_win.h" 5 #include "chrome/browser/sync/credential_cache_service_win.h"
6 6
7 #include "base/base64.h"
7 #include "base/bind.h" 8 #include "base/bind.h"
8 #include "base/bind_helpers.h" 9 #include "base/bind_helpers.h"
9 #include "base/base64.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
11 #include "base/compiler_specific.h" 11 #include "base/compiler_specific.h"
12 #include "base/file_util.h" 12 #include "base/file_util.h"
13 #include "base/string_number_conversions.h" 13 #include "base/string_number_conversions.h"
14 #include "base/time.h" 14 #include "base/time.h"
15 #include "base/values.h" 15 #include "base/values.h"
16 #include "base/win/windows_version.h" 16 #include "base/win/windows_version.h"
17 #include "chrome/browser/prefs/pref_service.h" 17 #include "chrome/browser/prefs/pref_service.h"
18 #include "chrome/browser/profiles/profile.h" 18 #include "chrome/browser/profiles/profile.h"
19 #include "chrome/browser/profiles/profile_manager.h" 19 #include "chrome/browser/profiles/profile_manager.h"
20 #include "chrome/browser/signin/signin_manager.h" 20 #include "chrome/browser/signin/signin_manager.h"
21 #include "chrome/browser/signin/signin_manager_factory.h" 21 #include "chrome/browser/signin/signin_manager_factory.h"
22 #include "chrome/browser/signin/token_service.h" 22 #include "chrome/browser/signin/token_service.h"
23 #include "chrome/browser/signin/token_service_factory.h" 23 #include "chrome/browser/signin/token_service_factory.h"
24 #include "chrome/browser/sync/credential_cache_service_factory_win.h" 24 #include "chrome/browser/sync/credential_cache_service_factory_win.h"
25 #include "chrome/browser/sync/glue/chrome_encryptor.h" 25 #include "chrome/browser/sync/glue/chrome_encryptor.h"
26 #include "chrome/browser/sync/profile_sync_service.h" 26 #include "chrome/browser/sync/profile_sync_service.h"
27 #include "chrome/browser/sync/profile_sync_service_factory.h" 27 #include "chrome/browser/sync/profile_sync_service_factory.h"
28 #include "chrome/common/chrome_constants.h" 28 #include "chrome/common/chrome_constants.h"
29 #include "chrome/common/chrome_notification_types.h" 29 #include "chrome/common/chrome_notification_types.h"
30 #include "chrome/common/chrome_paths_internal.h" 30 #include "chrome/common/chrome_paths_internal.h"
31 #include "chrome/common/chrome_switches.h" 31 #include "chrome/common/chrome_switches.h"
32 #include "chrome/common/net/gaia/gaia_auth_consumer.h"
33 #include "chrome/common/net/gaia/gaia_constants.h"
34 #include "chrome/common/pref_names.h" 32 #include "chrome/common/pref_names.h"
35 #include "content/public/browser/browser_thread.h" 33 #include "content/public/browser/browser_thread.h"
36 #include "content/public/browser/notification_details.h" 34 #include "content/public/browser/notification_details.h"
37 #include "content/public/browser/notification_source.h" 35 #include "content/public/browser/notification_source.h"
36 #include "google_apis/gaia/gaia_auth_consumer.h"
37 #include "google_apis/gaia/gaia_constants.h"
38 #include "sync/internal_api/public/base/model_type.h" 38 #include "sync/internal_api/public/base/model_type.h"
39 39
40 namespace syncer { 40 namespace syncer {
41 41
42 // The time delay (in seconds) between two consecutive polls of the alternate 42 // The time delay (in seconds) between two consecutive polls of the alternate
43 // credential cache. A two minute delay seems like a reasonable amount of time 43 // credential cache. A two minute delay seems like a reasonable amount of time
44 // in which to propagate changes to signed in state between Metro and Desktop. 44 // in which to propagate changes to signed in state between Metro and Desktop.
45 const int kCredentialCachePollIntervalSecs = 2 * 60; 45 const int kCredentialCachePollIntervalSecs = 2 * 60;
46 46
47 // Keeps track of the last time a credential cache was written to. Used to make 47 // Keeps track of the last time a credential cache was written to. Used to make
(...skipping 821 matching lines...) Expand 10 before | Expand all | Expand 10 after
869 !HasUserSignedOut() && 869 !HasUserSignedOut() &&
870 !alternate_google_services_username.empty() && 870 !alternate_google_services_username.empty() &&
871 !alternate_lsid.empty() && 871 !alternate_lsid.empty() &&
872 !alternate_sid.empty() && 872 !alternate_sid.empty() &&
873 !(alternate_encryption_bootstrap_token.empty() && 873 !(alternate_encryption_bootstrap_token.empty() &&
874 alternate_keystore_encryption_bootstrap_token.empty()) && 874 alternate_keystore_encryption_bootstrap_token.empty()) &&
875 !service->setup_in_progress(); 875 !service->setup_in_progress();
876 } 876 }
877 877
878 } // namespace syncer 878 } // namespace syncer
OLDNEW
« no previous file with comments | « chrome/browser/signin/ubertoken_fetcher_unittest.cc ('k') | chrome/browser/sync/credential_cache_service_win_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698