Merge "Fix locked second screen on boot" into rvc-dev am: 2455e98420 am: 09960b9491
Change-Id: I1b793d3661730a2315439a078793f72c33759434
This commit is contained in:
@@ -126,12 +126,14 @@ public class KeyguardDisplayManager {
|
|||||||
final int displayId = display.getDisplayId();
|
final int displayId = display.getDisplayId();
|
||||||
Presentation presentation = mPresentations.get(displayId);
|
Presentation presentation = mPresentations.get(displayId);
|
||||||
if (presentation == null) {
|
if (presentation == null) {
|
||||||
presentation = new KeyguardPresentation(mContext, display, mInjectableInflater);
|
final Presentation newPresentation =
|
||||||
presentation.setOnDismissListener(dialog -> {
|
new KeyguardPresentation(mContext, display, mInjectableInflater);
|
||||||
if (null != mPresentations.get(displayId)) {
|
newPresentation.setOnDismissListener(dialog -> {
|
||||||
|
if (newPresentation.equals(mPresentations.get(displayId))) {
|
||||||
mPresentations.remove(displayId);
|
mPresentations.remove(displayId);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
presentation = newPresentation;
|
||||||
try {
|
try {
|
||||||
presentation.show();
|
presentation.show();
|
||||||
} catch (WindowManager.InvalidDisplayException ex) {
|
} catch (WindowManager.InvalidDisplayException ex) {
|
||||||
|
|||||||
Reference in New Issue
Block a user