Metrics for user choices in storage wizard.
These metrics help us understand more about how users in the field are interacting with adoptable storage. Bug: 37284068 Test: atest com.android.settings.ui.StorageWizardTest Change-Id: I2bb9b5b3683c6ed080233aa595c2626685384923
This commit is contained in:
@@ -25,7 +25,9 @@ import android.os.storage.VolumeInfo;
|
||||
import android.view.View;
|
||||
import android.widget.Button;
|
||||
|
||||
import com.android.internal.logging.nano.MetricsProto.MetricsEvent;
|
||||
import com.android.settings.R;
|
||||
import com.android.settings.overlay.FeatureFactory;
|
||||
|
||||
public class StorageWizardInit extends StorageWizardBase {
|
||||
private Button mExternal;
|
||||
@@ -68,6 +70,12 @@ public class StorageWizardInit extends StorageWizardBase {
|
||||
}
|
||||
|
||||
public void onNavigateExternal(View view) {
|
||||
if (view != null) {
|
||||
// User made an explicit choice for external
|
||||
FeatureFactory.getFactory(this).getMetricsFeatureProvider().action(this,
|
||||
MetricsEvent.ACTION_STORAGE_INIT_EXTERNAL);
|
||||
}
|
||||
|
||||
if (mVolume != null && mVolume.getType() == VolumeInfo.TYPE_PUBLIC
|
||||
&& mVolume.getState() != VolumeInfo.STATE_UNMOUNTABLE) {
|
||||
// Remember that user made decision
|
||||
@@ -85,6 +93,12 @@ public class StorageWizardInit extends StorageWizardBase {
|
||||
}
|
||||
|
||||
public void onNavigateInternal(View view) {
|
||||
if (view != null) {
|
||||
// User made an explicit choice for internal
|
||||
FeatureFactory.getFactory(this).getMetricsFeatureProvider().action(this,
|
||||
MetricsEvent.ACTION_STORAGE_INIT_INTERNAL);
|
||||
}
|
||||
|
||||
StorageWizardFormatConfirm.showPrivate(this, mDisk.getId());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user