Index: chrome/android/java/src/org/chromium/chrome/browser/firstrun/FirstRunFlowSequencer.java |
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/firstrun/FirstRunFlowSequencer.java b/chrome/android/java/src/org/chromium/chrome/browser/firstrun/FirstRunFlowSequencer.java |
index faa062f7a375273ce5796966e87b7b093dce6087..8a9579f7062e7991312f81bf5dceb40fa85814af 100644 |
--- a/chrome/android/java/src/org/chromium/chrome/browser/firstrun/FirstRunFlowSequencer.java |
+++ b/chrome/android/java/src/org/chromium/chrome/browser/firstrun/FirstRunFlowSequencer.java |
@@ -39,13 +39,6 @@ public abstract class FirstRunFlowSequencer { |
private final Bundle mLaunchProperties; |
/** |
- * Determines if the metrics reporting checkbox is initially checked when shown to the user. If |
- * reporting is opt-in, then it won't be checked. |
- */ |
- @VisibleForTesting |
- protected boolean mIsMetricsReportingOptIn; |
- |
- /** |
* Callback that is called once the flow is determined. |
* If the properties is null, the First Run experience needs to finish and |
* restart the original intent if necessary. |
@@ -53,11 +46,9 @@ public abstract class FirstRunFlowSequencer { |
*/ |
public abstract void onFlowIsKnown(Bundle freProperties); |
- public FirstRunFlowSequencer( |
- Activity activity, Bundle launcherProvidedProperties, boolean isMetricsReportingOptIn) { |
+ public FirstRunFlowSequencer(Activity activity, Bundle launcherProvidedProperties) { |
mActivity = activity; |
mLaunchProperties = launcherProvidedProperties; |
- mIsMetricsReportingOptIn = isMetricsReportingOptIn; |
} |
/** |
@@ -126,8 +117,9 @@ public abstract class FirstRunFlowSequencer { |
} |
@VisibleForTesting |
- protected void enableCrashUpload() { |
- PrivacyPreferencesManager.getInstance().initCrashUploadPreference(true); |
+ protected void setDefaultUsageAndCrashReporting() { |
+ PrivacyPreferencesManager.getInstance().initCrashUploadPreference( |
+ FirstRunActivity.DEFAULT_USAGE_CRASH_REPORTING); |
} |
Ilya Sherman
2016/08/25 19:56:51
Hmm, it seems like it would make sense to inline t
gayane -on leave until 09-2017
2016/08/25 20:50:15
Lets do that in follow-up CL, because I also need
|
@VisibleForTesting |
@@ -159,12 +151,10 @@ public abstract class FirstRunFlowSequencer { |
boolean showWelcomePage = !forceEduSignIn; |
freProperties.putBoolean(FirstRunActivity.SHOW_WELCOME_PAGE, showWelcomePage); |
- // Enable reporting by default on non-Stable releases. |
- // The user can turn it off on the Welcome page. |
+ // Initialize usage and crash reporting according to default value. |
Ilya Sherman
2016/08/25 19:56:51
nit: s/to default/to the default
gayane -on leave until 09-2017
2016/08/25 20:50:15
Done.
|
+ // The user can change it on the Welcome page. |
Ilya Sherman
2016/08/25 19:56:51
nit: I'd phrase this as "The user can explicitly e
gayane -on leave until 09-2017
2016/08/25 20:50:15
Done.
|
// This is controlled by the administrator via a policy on EDU devices. |
- if (!mIsMetricsReportingOptIn) { |
- enableCrashUpload(); |
- } |
+ setDefaultUsageAndCrashReporting(); |
// We show the sign-in page if sync is allowed, and not signed in, and this is not an EDU |
// device, and |