Loading src/com/android/settings/CryptKeeper.java +6 −5 Original line number Diff line number Diff line Loading @@ -33,11 +33,11 @@ import android.os.Message; import android.os.PowerManager; import android.os.RemoteException; import android.os.ServiceManager; import android.os.SystemProperties; import android.os.UserHandle; import android.os.storage.IStorageManager; import android.os.storage.StorageManager; import android.provider.Settings; import android.sysprop.VoldProperties; import android.telecom.TelecomManager; import android.telephony.TelephonyManager; import android.text.Editable; Loading Loading @@ -400,7 +400,7 @@ public class CryptKeeper extends Activity implements TextView.OnEditorActionList super.onCreate(savedInstanceState); // If we are not encrypted or encrypting, get out quickly. final String state = VoldProperties.decrypt().orElse(""); final String state = SystemProperties.get("vold.decrypt"); if (!isDebugView() && ("".equals(state) || DECRYPT_STATE.equals(state))) { disableCryptKeeperComponent(this); // Typically CryptKeeper is launched as the home app. We didn't Loading Loading @@ -468,7 +468,7 @@ public class CryptKeeper extends Activity implements TextView.OnEditorActionList return; } final String progress = VoldProperties.encrypt_progress().orElse(""); final String progress = SystemProperties.get("vold.encrypt_progress"); if (!"".equals(progress) || isDebugView(FORCE_VIEW_PROGRESS)) { setContentView(R.layout.crypt_keeper_progress); encryptionProgressInit(); Loading Loading @@ -636,7 +636,7 @@ public class CryptKeeper extends Activity implements TextView.OnEditorActionList } private void updateProgress() { final String state = VoldProperties.encrypt_progress().orElse(""); final String state = SystemProperties.get("vold.encrypt_progress"); if ("error_partially_encrypted".equals(state)) { showFactoryReset(false); Loading @@ -657,7 +657,8 @@ public class CryptKeeper extends Activity implements TextView.OnEditorActionList // Now try to get status as time remaining and replace as appropriate Log.v(TAG, "Encryption progress: " + progress); try { int time = VoldProperties.encrypt_time_remaining().get(); final String timeProperty = SystemProperties.get("vold.encrypt_time_remaining"); int time = Integer.parseInt(timeProperty); if (time >= 0) { // Round up to multiple of 10 - this way display is less jerky time = (time + 9) / 10 * 10; Loading src/com/android/settings/MasterClear.java +1 −2 Original line number Diff line number Diff line Loading @@ -39,7 +39,6 @@ import android.os.UserHandle; import android.os.UserManager; import android.provider.Settings; import androidx.annotation.VisibleForTesting; import android.sysprop.VoldProperties; import android.telephony.euicc.EuiccManager; import android.text.TextUtils; import android.util.Log; Loading Loading @@ -405,7 +404,7 @@ public class MasterClear extends InstrumentedFragment implements OnGlobalLayoutL } private boolean isExtStorageEncrypted() { String state = VoldProperties.decrypt().orElse(""); String state = SystemProperties.get("vold.decrypt"); return !"".equals(state); } Loading Loading
src/com/android/settings/CryptKeeper.java +6 −5 Original line number Diff line number Diff line Loading @@ -33,11 +33,11 @@ import android.os.Message; import android.os.PowerManager; import android.os.RemoteException; import android.os.ServiceManager; import android.os.SystemProperties; import android.os.UserHandle; import android.os.storage.IStorageManager; import android.os.storage.StorageManager; import android.provider.Settings; import android.sysprop.VoldProperties; import android.telecom.TelecomManager; import android.telephony.TelephonyManager; import android.text.Editable; Loading Loading @@ -400,7 +400,7 @@ public class CryptKeeper extends Activity implements TextView.OnEditorActionList super.onCreate(savedInstanceState); // If we are not encrypted or encrypting, get out quickly. final String state = VoldProperties.decrypt().orElse(""); final String state = SystemProperties.get("vold.decrypt"); if (!isDebugView() && ("".equals(state) || DECRYPT_STATE.equals(state))) { disableCryptKeeperComponent(this); // Typically CryptKeeper is launched as the home app. We didn't Loading Loading @@ -468,7 +468,7 @@ public class CryptKeeper extends Activity implements TextView.OnEditorActionList return; } final String progress = VoldProperties.encrypt_progress().orElse(""); final String progress = SystemProperties.get("vold.encrypt_progress"); if (!"".equals(progress) || isDebugView(FORCE_VIEW_PROGRESS)) { setContentView(R.layout.crypt_keeper_progress); encryptionProgressInit(); Loading Loading @@ -636,7 +636,7 @@ public class CryptKeeper extends Activity implements TextView.OnEditorActionList } private void updateProgress() { final String state = VoldProperties.encrypt_progress().orElse(""); final String state = SystemProperties.get("vold.encrypt_progress"); if ("error_partially_encrypted".equals(state)) { showFactoryReset(false); Loading @@ -657,7 +657,8 @@ public class CryptKeeper extends Activity implements TextView.OnEditorActionList // Now try to get status as time remaining and replace as appropriate Log.v(TAG, "Encryption progress: " + progress); try { int time = VoldProperties.encrypt_time_remaining().get(); final String timeProperty = SystemProperties.get("vold.encrypt_time_remaining"); int time = Integer.parseInt(timeProperty); if (time >= 0) { // Round up to multiple of 10 - this way display is less jerky time = (time + 9) / 10 * 10; Loading
src/com/android/settings/MasterClear.java +1 −2 Original line number Diff line number Diff line Loading @@ -39,7 +39,6 @@ import android.os.UserHandle; import android.os.UserManager; import android.provider.Settings; import androidx.annotation.VisibleForTesting; import android.sysprop.VoldProperties; import android.telephony.euicc.EuiccManager; import android.text.TextUtils; import android.util.Log; Loading Loading @@ -405,7 +404,7 @@ public class MasterClear extends InstrumentedFragment implements OnGlobalLayoutL } private boolean isExtStorageEncrypted() { String state = VoldProperties.decrypt().orElse(""); String state = SystemProperties.get("vold.decrypt"); return !"".equals(state); } Loading