From 6f12864776ac6bdda8d4fa0aef48134605e93804 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20M=C3=BCllner?= Date: Fri, 14 Feb 2020 22:26:56 +0100 Subject: [PATCH] screenShield: Always deactivate when interrupting idle before lock With the old screen shield, we were simply hiding the lightboxes to show the shield when the user became active after activating the shield but before locking the screen (that is, when using a lock-delay). However now that the shield is gone, we end up showing the unlock dialog even though we are not actually locked. We probably don't want to add back a shield-like mode (that is, a way to raise the unlock dialog without authentication when we aren't locked), so just deactivate the whole shield when the user becomes active again before the lock kicks in. https://gitlab.gnome.org/GNOME/gnome-shell/issues/2213 --- js/ui/screenShield.js | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/js/ui/screenShield.js b/js/ui/screenShield.js index 5c0b76a75..0b5e844d8 100644 --- a/js/ui/screenShield.js +++ b/js/ui/screenShield.js @@ -281,11 +281,7 @@ var ScreenShield = class { // This function gets called here when the user becomes active // after we activated a lightbox // There are two possibilities here: - // - we're called when already locked/active; isLocked or isActive is true, - // we just go back to the lock screen curtain - // (isActive == isLocked == true: normal case - // isActive == false, isLocked == true: during the fade for manual locking - // isActive == true, isLocked == false: after session idle, before lock-delay) + // - we're called when already locked; we just go back to the lock screen curtain // - we're called because the session is IDLE but before the lightbox // is fully shown; at this point isActive is false, so we just hide // the lightbox, reset the activationTime and go back to the unlocked @@ -299,7 +295,7 @@ var ScreenShield = class { this.idleMonitor.remove_watch(this._becameActiveId); this._becameActiveId = 0; - if (this._isActive || this._isLocked) { + if (this._isLocked) { this._longLightbox.lightOff(); this._shortLightbox.lightOff(); } else {