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

Unified Diff: chrome/browser/chromeos/arc/arc_session_manager.h

Issue 2708923013: Split ArcSessionManager::OnPrimaryUserProfilePrepared(). (Closed)
Patch Set: rebase Created 3 years, 10 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/chromeos/arc/arc_session_manager.h
diff --git a/chrome/browser/chromeos/arc/arc_session_manager.h b/chrome/browser/chromeos/arc/arc_session_manager.h
index d5192354ba0826e00b869fefa7bd31eb77a04cc7..fba0655f2cd7932501d2c4b18af762c6ef266a8b 100644
--- a/chrome/browser/chromeos/arc/arc_session_manager.h
+++ b/chrome/browser/chromeos/arc/arc_session_manager.h
@@ -121,14 +121,26 @@ class ArcSessionManager : public ArcSessionObserver,
// has different meaning. Clean this up.
bool IsAllowed() const;
- void OnPrimaryUserProfilePrepared(Profile* profile);
void Shutdown();
+ // Sets the |profile|, and sets up Profile related fields in this instance.
+ // IsArcAllowedForProfile() must return true for the given |profile|.
+ void SetProfile(Profile* profile);
+
Profile* profile() { return profile_; }
const Profile* profile() const { return profile_; }
State state() const { return state_; }
+ // Starts observing Google Play Store enabled preference change.
+ // Also, based on its initial value, this may start ArcSession, or may start
+ // removing the data, as initial state.
+ // In addition, this triggers to show ArcAuthNotification, if necessary.
+ // Note that this must be called after SetProfile().
+ // TODO(hidehiko): Extract preference related code into a class to split the
+ // dependencty.
+ void StartPreferenceHandler();
+
// Adds or removes observers.
void AddObserver(Observer* observer);
void RemoveObserver(Observer* observer);
@@ -235,8 +247,6 @@ class ArcSessionManager : public ArcSessionObserver,
void OnAndroidManagementPassed();
void OnArcDataRemoved(bool success);
void OnArcSignInTimeout();
- void FetchAuthCode();
- void PrepareContextForAuthCodeRequest();
void StartArcAndroidManagementCheck();
void MaybeReenableArc();
« no previous file with comments | « chrome/browser/chromeos/arc/arc_service_launcher.cc ('k') | chrome/browser/chromeos/arc/arc_session_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698