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

Commit 160674fe authored by Lucas Dupin's avatar Lucas Dupin Committed by android-build-merger
Browse files

Merge "Avoid binder calls when unlocking" into pi-dev

am: 664956a5

Change-Id: Ib3405ef035e18e482a0ddea632bf1af5701c3820
parents 2c586725 664956a5
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -708,6 +708,11 @@ public class KeyguardUpdateMonitor implements TrustManager.TrustListener {
        return mStrongAuthTracker.isUnlockingWithFingerprintAllowed();
    }

    public boolean isUserInLockdown(int userId) {
        return mStrongAuthTracker.getStrongAuthForUser(userId)
                == LockPatternUtils.StrongAuthTracker.STRONG_AUTH_REQUIRED_AFTER_USER_LOCKDOWN;
    }

    public boolean needsSlowUnlockTransition() {
        return mNeedsSlowUnlockTransition;
    }
+2 −4
Original line number Diff line number Diff line
@@ -39,7 +39,7 @@ import android.widget.Toast;

import com.android.internal.statusbar.IStatusBarService;
import com.android.internal.statusbar.NotificationVisibility;
import com.android.internal.widget.LockPatternUtils;
import com.android.keyguard.KeyguardUpdateMonitor;
import com.android.systemui.Dependency;
import com.android.systemui.Dumpable;
import com.android.systemui.OverviewProxyService;
@@ -68,7 +68,6 @@ public class NotificationLockscreenUserManager implements Dumpable {
            Dependency.get(DeviceProvisionedController.class);
    private final UserManager mUserManager;
    private final IStatusBarService mBarService;
    private final LockPatternUtils mLockPatternUtils;

    private boolean mShowLockscreenNotifications;
    private boolean mAllowLockscreenRemoteInput;
@@ -162,7 +161,6 @@ public class NotificationLockscreenUserManager implements Dumpable {
        mCurrentUserId = ActivityManager.getCurrentUser();
        mBarService = IStatusBarService.Stub.asInterface(
                ServiceManager.getService(Context.STATUS_BAR_SERVICE));
        mLockPatternUtils = new LockPatternUtils(mContext);
    }

    public void setUpWithPresenter(NotificationPresenter presenter,
@@ -274,7 +272,7 @@ public class NotificationLockscreenUserManager implements Dumpable {
        if (userId == UserHandle.USER_ALL) {
            userId = mCurrentUserId;
        }
        return mLockPatternUtils.isUserInLockdown(userId);
        return KeyguardUpdateMonitor.getInstance(mContext).isUserInLockdown(userId);
    }

    /**
+5 −0
Original line number Diff line number Diff line
@@ -18,6 +18,7 @@ package com.android.systemui.statusbar;

import android.content.Context;
import android.content.res.Resources;
import android.os.Trace;
import android.service.notification.NotificationListenerService;
import android.util.Log;
import android.view.View;
@@ -283,6 +284,7 @@ public class NotificationViewHierarchyManager {
     * Updates expanded, dimmed and locked states of notification rows.
     */
    public void updateRowStates() {
        Trace.beginSection("NotificationViewHierarchyManager#updateRowStates");
        final int N = mListContainer.getContainerChildCount();

        int visibleNotifications = 0;
@@ -352,6 +354,9 @@ public class NotificationViewHierarchyManager {
            row.showAppOpsIcons(entry.mActiveAppOps);
        }

        Trace.beginSection("NotificationPresenter#onUpdateRowStates");
        mPresenter.onUpdateRowStates();
        Trace.endSection();
        Trace.endSection();
    }
}
+11 −10
Original line number Diff line number Diff line
@@ -3888,7 +3888,6 @@ public class StatusBar extends SystemUI implements DemoMode,
        mKeyguardIndicationController.setDozing(mDozing);
        mNotificationPanel.setDozing(mDozing, animate);
        updateQsExpansionEnabled();
        mViewHierarchyManager.updateRowStates();
        Trace.endSection();
    }

@@ -4676,6 +4675,7 @@ public class StatusBar extends SystemUI implements DemoMode,
                FingerprintUnlockController.MODE_WAKE_AND_UNLOCK) {
            dozing = false;
        }
        if (mDozing != dozing) {
            mDozing = dozing;
            mKeyguardViewMediator.setAodShowing(mDozing && alwaysOn);
            mStatusBarWindowManager.setDozing(mDozing);
@@ -4686,6 +4686,7 @@ public class StatusBar extends SystemUI implements DemoMode,
            mEntryManager.updateNotifications();
            updateDozingState();
            updateReportRejectedTouchVisibility();
        }
        Trace.endSection();
    }