Storage accessors; persist nickname, flags.

Move to using new public accessors on DiskInfo and VolumeInfo.

Persist nickname changes, and remember when user has initialized a
public volume.  Also skip the migration part of storage wizard until
it's implemented.

Bug: 19993667
Change-Id: I642fb43afb95380fddd48a1dad438e87b06454da
This commit is contained in:
Jeff Sharkey
2015-04-14 21:42:46 -07:00
parent 2949a4ab4d
commit 4366b565e1
15 changed files with 83 additions and 63 deletions

View File

@@ -59,9 +59,9 @@ public class StorageWizardFormatProgress extends StorageWizardBase {
protected Exception doInBackground(Void... params) {
try {
if (mFormatPublic) {
mStorage.partitionPublic(mDisk.id);
mStorage.partitionPublic(mDisk.getId());
} else {
mStorage.partitionPrivate(mDisk.id);
mStorage.partitionPrivate(mDisk.getId());
}
return null;
} catch (Exception e) {
@@ -74,8 +74,12 @@ public class StorageWizardFormatProgress extends StorageWizardBase {
final Context context = StorageWizardFormatProgress.this;
if (e == null) {
if (!mFormatPublic) {
final Intent intent = new Intent(context, StorageWizardMigrate.class);
intent.putExtra(DiskInfo.EXTRA_DISK_ID, mDisk.id);
// TODO: bring back migration once implemented
// final Intent intent = new Intent(context, StorageWizardMigrate.class);
// intent.putExtra(DiskInfo.EXTRA_DISK_ID, mDisk.getId());
// startActivity(intent);
final Intent intent = new Intent(context, StorageWizardReady.class);
intent.putExtra(DiskInfo.EXTRA_DISK_ID, mDisk.getId());
startActivity(intent);
}
finishAffinity();