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

Side by Side Diff: chrome/browser/sync_file_system/drive_backend/sync_engine.cc

Issue 502343002: Add account_id to signin manager notifications. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@isauth
Patch Set: Fix android trybots Created 6 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_file_system/drive_backend/sync_engine.h" 5 #include "chrome/browser/sync_file_system/drive_backend/sync_engine.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/metrics/histogram.h" 10 #include "base/metrics/histogram.h"
(...skipping 684 matching lines...) Expand 10 before | Expand all | Expand 10 after
695 } 695 }
696 696
697 } 697 }
698 698
699 void SyncEngine::GoogleSigninFailed(const GoogleServiceAuthError& error) { 699 void SyncEngine::GoogleSigninFailed(const GoogleServiceAuthError& error) {
700 Reset(); 700 Reset();
701 UpdateServiceState(REMOTE_SERVICE_AUTHENTICATION_REQUIRED, 701 UpdateServiceState(REMOTE_SERVICE_AUTHENTICATION_REQUIRED,
702 "Failed to sign in."); 702 "Failed to sign in.");
703 } 703 }
704 704
705 void SyncEngine::GoogleSigninSucceeded(const std::string& username, 705 void SyncEngine::GoogleSigninSucceeded(const std::string& account_id,
706 const std::string& username,
706 const std::string& password) { 707 const std::string& password) {
707 Initialize(); 708 Initialize();
708 } 709 }
709 710
710 void SyncEngine::GoogleSignedOut(const std::string& username) { 711 void SyncEngine::GoogleSignedOut(const std::string& account_id,
712 const std::string& username) {
711 Reset(); 713 Reset();
712 UpdateServiceState(REMOTE_SERVICE_AUTHENTICATION_REQUIRED, 714 UpdateServiceState(REMOTE_SERVICE_AUTHENTICATION_REQUIRED,
713 "User signed out."); 715 "User signed out.");
714 } 716 }
715 717
716 SyncEngine::SyncEngine( 718 SyncEngine::SyncEngine(
717 const scoped_refptr<base::SingleThreadTaskRunner>& ui_task_runner, 719 const scoped_refptr<base::SingleThreadTaskRunner>& ui_task_runner,
718 const scoped_refptr<base::SequencedTaskRunner>& worker_task_runner, 720 const scoped_refptr<base::SequencedTaskRunner>& worker_task_runner,
719 const scoped_refptr<base::SequencedTaskRunner>& drive_task_runner, 721 const scoped_refptr<base::SequencedTaskRunner>& drive_task_runner,
720 const base::FilePath& sync_file_system_dir, 722 const base::FilePath& sync_file_system_dir,
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
780 782
781 SyncStatusCallback SyncEngine::TrackCallback( 783 SyncStatusCallback SyncEngine::TrackCallback(
782 const SyncStatusCallback& callback) { 784 const SyncStatusCallback& callback) {
783 return callback_tracker_.Register( 785 return callback_tracker_.Register(
784 base::Bind(callback, SYNC_STATUS_ABORT), 786 base::Bind(callback, SYNC_STATUS_ABORT),
785 callback); 787 callback);
786 } 788 }
787 789
788 } // namespace drive_backend 790 } // namespace drive_backend
789 } // namespace sync_file_system 791 } // namespace sync_file_system
OLDNEW
« no previous file with comments | « chrome/browser/sync_file_system/drive_backend/sync_engine.h ('k') | chrome/browser/ui/app_list/app_list_view_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698