Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3244294c authored by Yo Chiang's avatar Yo Chiang Committed by android-build-merger
Browse files

Merge "VerificationActivity clones calling Intent"

am: ff266fb0

Change-Id: I95b7b712d64f058a527a9b72a315a62f60897284
parents b6bf5042 ff266fb0
Loading
Loading
Loading
Loading
+2 −12
Original line number Diff line number Diff line
@@ -16,9 +16,6 @@

package com.android.dynsystem;

import static android.os.image.DynamicSystemClient.KEY_SYSTEM_SIZE;
import static android.os.image.DynamicSystemClient.KEY_USERDATA_SIZE;

import android.app.Activity;
import android.app.KeyguardManager;
import android.content.Context;
@@ -88,12 +85,8 @@ public class VerificationActivity extends Activity {
    private void startInstallationService() {
        // retrieve data from calling intent
        Intent callingIntent = getIntent();

        Uri url = callingIntent.getData();
        long systemSize = callingIntent.getLongExtra(KEY_SYSTEM_SIZE, 0);
        long userdataSize = callingIntent.getLongExtra(KEY_USERDATA_SIZE, 0);
        boolean enableWhenCompleted = callingIntent.getBooleanExtra(
                DynamicSystemInstallationService.KEY_ENABLE_WHEN_COMPLETED, false);
        Bundle extras = callingIntent.getExtras();

        sVerifiedUrl = url.toString();

@@ -101,10 +94,7 @@ public class VerificationActivity extends Activity {
        Intent intent = new Intent(this, DynamicSystemInstallationService.class);
        intent.setData(url);
        intent.setAction(DynamicSystemClient.ACTION_START_INSTALL);
        intent.putExtra(KEY_SYSTEM_SIZE, systemSize);
        intent.putExtra(KEY_USERDATA_SIZE, userdataSize);
        intent.putExtra(
                DynamicSystemInstallationService.KEY_ENABLE_WHEN_COMPLETED, enableWhenCompleted);
        intent.putExtras(extras);

        Log.d(TAG, "Starting Installation Service");
        startServiceAsUser(intent, UserHandle.SYSTEM);