Index: chrome/browser/chromeos/login/enrollment/enrollment_screen.h |
diff --git a/chrome/browser/chromeos/login/enrollment/enrollment_screen.h b/chrome/browser/chromeos/login/enrollment/enrollment_screen.h |
index 9bd361d02b6e9e8e6dcc67087a95b164bba53c67..97f3ac0c53b0d13ca1d212774f77176c5f14168f 100644 |
--- a/chrome/browser/chromeos/login/enrollment/enrollment_screen.h |
+++ b/chrome/browser/chromeos/login/enrollment/enrollment_screen.h |
@@ -13,12 +13,14 @@ |
#include "base/gtest_prod_util.h" |
#include "base/macros.h" |
#include "base/memory/weak_ptr.h" |
+#include "base/timer/timer.h" |
#include "chrome/browser/chromeos/login/enrollment/enrollment_screen_actor.h" |
#include "chrome/browser/chromeos/login/enrollment/enterprise_enrollment_helper.h" |
#include "chrome/browser/chromeos/login/screens/base_screen.h" |
#include "chrome/browser/chromeos/policy/enrollment_config.h" |
#include "components/policy/core/common/cloud/cloud_policy_constants.h" |
#include "components/policy/core/common/cloud/enterprise_metrics.h" |
+#include "net/base/backoff_entry.h" |
namespace base { |
class ElapsedTimer; |
@@ -146,6 +148,14 @@ class EnrollmentScreen |
// Advance to the next authentication mechanism if possible. |
bool AdvanceToNextAuth(); |
+ // Similar to OnRetry(), but responds to a timer instead of the user |
+ // pressing the Retry button. |
+ void AutomaticRetry(); |
+ |
+ // Processes a request to retry enrollment. |
+ // Called by OnRetry() and AutomaticRetry(). |
+ void ProcessRetry(); |
+ |
pairing_chromeos::ControllerPairingController* shark_controller_ = nullptr; |
EnrollmentScreenActor* actor_; |
@@ -157,6 +167,10 @@ class EnrollmentScreen |
std::string enrolling_user_domain_; |
std::string auth_code_; |
std::unique_ptr<base::ElapsedTimer> elapsed_timer_; |
+ base::OneShotTimer retry_timer_; |
The one and only Dr. Crash
2016/12/06 22:24:33
Instead of using a timer, you can simply post dela
|
+ net::BackoffEntry::Policy retry_policy_; |
+ net::BackoffEntry retry_backoff_; |
+ int num_retries_; |
std::unique_ptr<EnterpriseEnrollmentHelper> enrollment_helper_; |
base::WeakPtrFactory<EnrollmentScreen> weak_ptr_factory_; |