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

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

Issue 2490093002: Migrate opt-in auth flow to re-auth flow. (Closed)
Patch Set: Created 4 years, 1 month 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_auth_service.h
diff --git a/chrome/browser/chromeos/arc/arc_auth_service.h b/chrome/browser/chromeos/arc/arc_auth_service.h
index 2dc71d255e2bc75332bafaeb93dd7489040246c4..c32f8c9b065b198c36f7527fc5ef405072829270 100644
--- a/chrome/browser/chromeos/arc/arc_auth_service.h
+++ b/chrome/browser/chromeos/arc/arc_auth_service.h
@@ -64,7 +64,6 @@ class ArcAuthService : public ArcService,
STOPPED, // ARC is not running.
TERMS, // Showing "Terms Of Service" to user.
ANDROID_MANAGEMENT_CHECK, // Checkng Android management status.
- FETCHING_CODE, // ARC is not yet running. Fetching auth token.
ACTIVE, // ARC is running.
};
@@ -112,8 +111,6 @@ class ArcAuthService : public ArcService,
State state() const { return state_; }
- std::string GetAndResetAuthCode();
-
// Adds or removes observers.
void AddObserver(Observer* observer);
void RemoveObserver(Observer* observer);
@@ -149,7 +146,7 @@ class ArcAuthService : public ArcService,
void StartLso();
// Called from Arc support platform app to set auth code and start arc.
- void SetAuthCodeAndStartArc(const std::string& auth_code);
+ void OnAuthCodeObtained(const std::string& auth_code);
// Called from Arc support platform app when user cancels signing.
void CancelAuthCode();
@@ -213,11 +210,12 @@ class ArcAuthService : public ArcService,
ArcSupportHost* support_host() { return support_host_.get(); }
+ void StartArc();
+
private:
using AccountInfoCallback = base::Callback<void(mojom::AccountInfoPtr)>;
class AccountInfoNotifier;
- void StartArc();
// TODO(hidehiko): move UI methods/fields to ArcSupportHost.
void ShowUI(ArcSupportHost::UIPage page, const base::string16& status);
void CloseUI();
@@ -261,11 +259,11 @@ class ArcAuthService : public ArcService,
State state_ = State::NOT_INITIALIZED;
base::ObserverList<Observer> observer_list_;
std::unique_ptr<ArcAppLauncher> playstore_launcher_;
- std::string auth_code_;
ArcSupportHost::UIPage ui_page_ = ArcSupportHost::UIPage::NO_PAGE;
base::string16 ui_page_status_;
bool clear_required_ = false;
bool reenable_arc_ = false;
+ bool arc_data_is_being_removed_ = false;
base::OneShotTimer arc_sign_in_timer_;
// Notifies the correct callback whenever the auth_code is ready.
« no previous file with comments | « no previous file | chrome/browser/chromeos/arc/arc_auth_service.cc » ('j') | chrome/browser/chromeos/arc/arc_auth_service.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698