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

Commit 54ba638e authored by Jorim Jaggi's avatar Jorim Jaggi Committed by Android (Google) Code Review
Browse files

Merge "Do not destroy the security method when pressing back." into lmp-preview-dev

parents 27958268 a0be6d53
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -39,7 +39,7 @@ public class KeyguardSimpleHostView extends KeyguardViewBase {

    @Override
    public void cleanUp() {
        // TODO Auto-generated method stub
        getSecurityContainer().onPause();
    }

    @Override
+6 −6
Original line number Diff line number Diff line
@@ -54,10 +54,6 @@ public class KeyguardBouncer {
        mWindowManager = windowManager;
    }

    public void prepare() {
        ensureView();
    }

    public void show() {
        ensureView();

@@ -75,11 +71,15 @@ public class KeyguardBouncer {
        show();
    }

    public void hide() {
    public void hide(boolean destroyView) {
        if (mKeyguardView != null) {
            mKeyguardView.cleanUp();
        }
        if (destroyView) {
            removeView();
        } else if (mRoot != null) {
            mRoot.setVisibility(View.INVISIBLE);
        }
    }

    /**
+4 −5
Original line number Diff line number Diff line
@@ -98,8 +98,7 @@ public class StatusBarKeyguardViewManager {
            mBouncer.show();
        } else {
            mPhoneStatusBar.showKeyguard();
            mBouncer.hide();
            mBouncer.prepare();
            mBouncer.hide(false /* destroyView */);
        }
    }

@@ -124,7 +123,7 @@ public class StatusBarKeyguardViewManager {
        if (mShowing) {
            if (mOccluded) {
                mPhoneStatusBar.hideKeyguard();
                mBouncer.hide();
                mBouncer.hide(false /* destroyView */);
            } else {
                showBouncerOrKeyguard();
            }
@@ -184,7 +183,7 @@ public class StatusBarKeyguardViewManager {
        mShowing = false;
        mPhoneStatusBar.hideKeyguard();
        mStatusBarWindowManager.setKeyguardShowing(false);
        mBouncer.hide();
        mBouncer.hide(true /* destroyView */);
        mViewMediatorCallback.keyguardGone();
        updateStates();
    }
@@ -216,7 +215,7 @@ public class StatusBarKeyguardViewManager {
     */
    public boolean onBackPressed() {
        if (mBouncer.isShowing()) {
            mBouncer.hide();
            mBouncer.hide(false /* destroyView */);
            mPhoneStatusBar.showKeyguard();
            updateStates();
            return true;