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

Side by Side Diff: chrome/browser/sync/engine/syncapi.cc

Issue 1161006: Make it clear what last_sync_timestamp actually tracks. Update (Closed)
Patch Set: Undo accidental patch-juggling mistake. Created 10 years, 9 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
OLDNEW
1 // Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2009 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/engine/syncapi.h" 5 #include "chrome/browser/sync/engine/syncapi.h"
6 6
7 #include "build/build_config.h" 7 #include "build/build_config.h"
8 8
9 #if defined(OS_WIN) 9 #if defined(OS_WIN)
10 #include <windows.h> 10 #include <windows.h>
(...skipping 1810 matching lines...) Expand 10 before | Expand all | Expand 10 after
1821 DCHECK(false) << "ScopedDirLookup creation failed; unable to hook " 1821 DCHECK(false) << "ScopedDirLookup creation failed; unable to hook "
1822 << "up directory change event listener!"; 1822 << "up directory change event listener!";
1823 return; 1823 return;
1824 } 1824 }
1825 dir_change_hookup_.reset(NewEventListenerHookup( 1825 dir_change_hookup_.reset(NewEventListenerHookup(
1826 lookup->changes_channel(), this, 1826 lookup->changes_channel(), this,
1827 &SyncInternal::HandleChangeEvent)); 1827 &SyncInternal::HandleChangeEvent));
1828 1828
1829 if (lookup->initial_sync_ended()) 1829 if (lookup->initial_sync_ended())
1830 MarkAndNotifyInitializationComplete(); 1830 MarkAndNotifyInitializationComplete();
1831
1832 // If we are transitioning from having bad to good credentials, that
1833 // could mean that the syncer can now make forward progress. Wake it.
1834 syncer_thread_->NudgeSyncer(0, SyncerThread::kLocal);
1835 } 1831 }
1836 return; 1832 return;
1837 // Authentication failures translate to GoogleServiceAuthError events. 1833 // Authentication failures translate to GoogleServiceAuthError events.
1838 case AuthWatcherEvent::GAIA_AUTH_FAILED: // Invalid GAIA credentials. 1834 case AuthWatcherEvent::GAIA_AUTH_FAILED: // Invalid GAIA credentials.
1839 if (event.auth_results->auth_error == browser_sync::CaptchaRequired) { 1835 if (event.auth_results->auth_error == browser_sync::CaptchaRequired) {
1840 auth_problem_ = AuthError::CAPTCHA_REQUIRED; 1836 auth_problem_ = AuthError::CAPTCHA_REQUIRED;
1841 std::string url_string("https://www.google.com/accounts/"); 1837 std::string url_string("https://www.google.com/accounts/");
1842 url_string += event.auth_results->captcha_url; 1838 url_string += event.auth_results->captcha_url;
1843 GURL captcha(url_string); 1839 GURL captcha(url_string);
1844 observer_->OnAuthError(AuthError::FromCaptchaChallenge( 1840 observer_->OnAuthError(AuthError::FromCaptchaChallenge(
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
1934 BaseTransaction::~BaseTransaction() { 1930 BaseTransaction::~BaseTransaction() {
1935 delete lookup_; 1931 delete lookup_;
1936 } 1932 }
1937 1933
1938 UserShare* SyncManager::GetUserShare() const { 1934 UserShare* SyncManager::GetUserShare() const {
1939 DCHECK(data_->initialized()) << "GetUserShare requires initialization!"; 1935 DCHECK(data_->initialized()) << "GetUserShare requires initialization!";
1940 return data_->GetUserShare(); 1936 return data_->GetUserShare();
1941 } 1937 }
1942 1938
1943 } // namespace sync_api 1939 } // namespace sync_api
OLDNEW
« no previous file with comments | « chrome/browser/sync/engine/store_timestamps_command.cc ('k') | chrome/browser/sync/engine/syncer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698