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

Side by Side Diff: components/signin/core/browser/signin_tracker.h

Issue 666133002: Standardize usage of virtual/override/final in components/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #ifndef COMPONENTS_SIGNIN_CORE_BROWSER_SIGNIN_TRACKER_H_ 5 #ifndef COMPONENTS_SIGNIN_CORE_BROWSER_SIGNIN_TRACKER_H_
6 #define COMPONENTS_SIGNIN_CORE_BROWSER_SIGNIN_TRACKER_H_ 6 #define COMPONENTS_SIGNIN_CORE_BROWSER_SIGNIN_TRACKER_H_
7 7
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "components/signin/core/browser/signin_manager.h" 9 #include "components/signin/core/browser/signin_manager.h"
10 #include "google_apis/gaia/google_service_auth_error.h" 10 #include "google_apis/gaia/google_service_auth_error.h"
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 // Creates a SigninTracker that tracks the signin status on the passed 68 // Creates a SigninTracker that tracks the signin status on the passed
69 // classes, and notifies the |observer| on status changes. All of the 69 // classes, and notifies the |observer| on status changes. All of the
70 // instances with the exception of |account_reconcilor| must be non-null and 70 // instances with the exception of |account_reconcilor| must be non-null and
71 // must outlive the SigninTracker. |account_reconcilor| will be used if it is 71 // must outlive the SigninTracker. |account_reconcilor| will be used if it is
72 // non-null. 72 // non-null.
73 SigninTracker(ProfileOAuth2TokenService* token_service, 73 SigninTracker(ProfileOAuth2TokenService* token_service,
74 SigninManagerBase* signin_manager, 74 SigninManagerBase* signin_manager,
75 AccountReconcilor* account_reconcilor, 75 AccountReconcilor* account_reconcilor,
76 SigninClient* client, 76 SigninClient* client,
77 Observer* observer); 77 Observer* observer);
78 virtual ~SigninTracker(); 78 ~SigninTracker() override;
79 79
80 // SigninManagerBase::Observer implementation. 80 // SigninManagerBase::Observer implementation.
81 virtual void GoogleSigninFailed(const GoogleServiceAuthError& error) override; 81 void GoogleSigninFailed(const GoogleServiceAuthError& error) override;
82 82
83 // OAuth2TokenService::Observer implementation. 83 // OAuth2TokenService::Observer implementation.
84 virtual void OnRefreshTokenAvailable(const std::string& account_id) override; 84 void OnRefreshTokenAvailable(const std::string& account_id) override;
85 virtual void OnRefreshTokenRevoked(const std::string& account_id) override; 85 void OnRefreshTokenRevoked(const std::string& account_id) override;
86 86
87 private: 87 private:
88 // Initializes this by adding notifications and observers. 88 // Initializes this by adding notifications and observers.
89 void Initialize(); 89 void Initialize();
90 90
91 // MergeSessionHelper::Observer implementation. 91 // MergeSessionHelper::Observer implementation.
92 virtual void MergeSessionCompleted( 92 void MergeSessionCompleted(const std::string& account_id,
93 const std::string& account_id, 93 const GoogleServiceAuthError& error) override;
94 const GoogleServiceAuthError& error) override;
95 94
96 // The classes whose collective signin status we are tracking. 95 // The classes whose collective signin status we are tracking.
97 ProfileOAuth2TokenService* token_service_; 96 ProfileOAuth2TokenService* token_service_;
98 SigninManagerBase* signin_manager_; 97 SigninManagerBase* signin_manager_;
99 AccountReconcilor* account_reconcilor_; 98 AccountReconcilor* account_reconcilor_;
100 99
101 // The client associated with this instance. 100 // The client associated with this instance.
102 SigninClient* client_; 101 SigninClient* client_;
103 102
104 // Weak pointer to the observer we call when the signin state changes. 103 // Weak pointer to the observer we call when the signin state changes.
105 Observer* observer_; 104 Observer* observer_;
106 105
107 DISALLOW_COPY_AND_ASSIGN(SigninTracker); 106 DISALLOW_COPY_AND_ASSIGN(SigninTracker);
108 }; 107 };
109 108
110 #endif // COMPONENTS_SIGNIN_CORE_BROWSER_SIGNIN_TRACKER_H_ 109 #endif // COMPONENTS_SIGNIN_CORE_BROWSER_SIGNIN_TRACKER_H_
OLDNEW
« no previous file with comments | « components/signin/core/browser/signin_oauth_helper.h ('k') | components/signin/core/browser/test_signin_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698