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

Commit 3629c607 authored by Mayank Garg's avatar Mayank Garg
Browse files

Car user switching dialog taking more than 3 seconds

Bug: 144706096
Bug: 145021634
Bug: 140999054
Bug: 145001354
Test: adb shell am instrument -w -r -e include_creation_time true -e iterations 10 -e class android.platform.test.scenario.multiuser.nonui.TEST_NAME android.platform.test.scenario/androidx.test.runner.AndroidJUnitRunner
      // for TEST_NAME SwitchToExistingSecondaryUserBenchmark, user switch time dropped from 5.2 seconds to 2.2 seconds
Change-Id: I5474c683725b22f3e15e9b80ac4209df028a7993
(cherry picked from commit dec438aa5c5ae5a54d7bc7ac788ec4936ae3e3ba)
parent 659f477f
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -37,6 +37,7 @@ import android.view.LayoutInflater;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;

import com.android.internal.R;


@@ -65,7 +66,9 @@ final class CarUserSwitchingDialog extends UserSwitchingDialog {
        setCancelable(false);
        Resources res = getContext().getResources();
        // Custom view due to alignment and font size requirements
        getContext().setTheme(R.style.Theme_DeviceDefault_Light_Dialog_Alert_UserSwitchingDialog);
        // TODO (b/145021634): disabled because it's delaying user switch by 3 seconds
        // getContext()
        // .setTheme(R.style.Theme_DeviceDefault_Light_Dialog_Alert_UserSwitchingDialog);
        View view = LayoutInflater.from(getContext()).inflate(
                R.layout.car_user_switching_dialog,
                null);