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

Unified Diff: chrome/browser/ui/app_list/app_list_view_delegate.h

Issue 405353003: Merge 278990 "Put back sign in / sign out / new user handling in..." (Closed) Base URL: svn://svn.chromium.org/chrome/branches/2062/src/
Patch Set: Created 6 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/app_list/app_list_view_delegate.h
===================================================================
--- chrome/browser/ui/app_list/app_list_view_delegate.h (revision 284629)
+++ chrome/browser/ui/app_list/app_list_view_delegate.h (working copy)
@@ -12,9 +12,12 @@
#include "base/compiler_specific.h"
#include "base/memory/scoped_ptr.h"
#include "base/observer_list.h"
+#include "base/scoped_observer.h"
#include "chrome/browser/profiles/profile_info_cache_observer.h"
#include "chrome/browser/search/hotword_client.h"
+#include "chrome/browser/signin/signin_manager_factory.h"
#include "chrome/browser/ui/app_list/start_page_observer.h"
+#include "components/signin/core/browser/signin_manager_base.h"
#include "ui/app_list/app_list_view_delegate.h"
class AppListControllerDelegate;
@@ -40,7 +43,9 @@
class AppListViewDelegate : public app_list::AppListViewDelegate,
public app_list::StartPageObserver,
public HotwordClient,
- public ProfileInfoCacheObserver {
+ public ProfileInfoCacheObserver,
+ public SigninManagerBase::Observer,
+ public SigninManagerFactory::Observer {
public:
AppListViewDelegate(Profile* profile,
AppListControllerDelegate* controller);
@@ -100,6 +105,16 @@
virtual void OnHotwordStateChanged(bool started) OVERRIDE;
virtual void OnHotwordRecognized() OVERRIDE;
+ // Overridden from SigninManagerFactory::Observer:
+ virtual void SigninManagerCreated(SigninManagerBase* manager) OVERRIDE;
+ virtual void SigninManagerShutdown(SigninManagerBase* manager) OVERRIDE;
+
+ // Overridden from SigninManagerBase::Observer:
+ virtual void GoogleSigninFailed(const GoogleServiceAuthError& error) OVERRIDE;
+ virtual void GoogleSigninSucceeded(const std::string& username,
+ const std::string& password) OVERRIDE;
+ virtual void GoogleSignedOut(const std::string& username) OVERRIDE;
+
// Overridden from ProfileInfoCacheObserver:
virtual void OnProfileAdded(const base::FilePath& profile_path) OVERRIDE;
virtual void OnProfileWasRemoved(const base::FilePath& profile_path,
@@ -130,6 +145,10 @@
ObserverList<app_list::AppListViewDelegateObserver> observers_;
+ // Used to track the SigninManagers that this instance is observing so that
+ // this instance can be removed as an observer on its destruction.
+ ScopedObserver<SigninManagerBase, AppListViewDelegate> scoped_observer_;
+
DISALLOW_COPY_AND_ASSIGN(AppListViewDelegate);
};
« no previous file with comments | « chrome/browser/ui/app_list/app_list_service_views_browsertest.cc ('k') | chrome/browser/ui/app_list/app_list_view_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698