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

Commit 99f31ae3 authored by Julius D'souza's avatar Julius D'souza Committed by Android (Google) Code Review
Browse files

Merge "Add conditions for Auto to isUserSetupComplete()"

parents 46b043f7 c30875d1
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -1468,10 +1468,17 @@ public class PhoneWindowManager implements WindowManagerPolicy {
                Settings.Secure.USER_SETUP_COMPLETE, 0, UserHandle.USER_CURRENT) != 0;
        if (mHasFeatureLeanback) {
            isSetupComplete &= isTvUserSetupComplete();
        } else if (mHasFeatureAuto) {
            isSetupComplete &= isAutoUserSetupComplete();
        }
        return isSetupComplete;
    }

    private boolean isAutoUserSetupComplete() {
        return Settings.Secure.getIntForUser(mContext.getContentResolver(),
                "android.car.SETUP_WIZARD_IN_PROGRESS", 0, UserHandle.USER_CURRENT) == 0;
    }

    private boolean isTvUserSetupComplete() {
        return Settings.Secure.getIntForUser(mContext.getContentResolver(),
                Settings.Secure.TV_USER_SETUP_COMPLETE, 0, UserHandle.USER_CURRENT) != 0;