gdm: make user list fade-in on vt switch more reliable

We fade out the authentication prompt when a user successfully
logs into a user session. We reset it and fade it back in when
the user switches back to the login screen VT.

The problem is, we only fade it back in if the auth prompt status is
VERIFICATION_SUCCEEDED.  It's possible for it to be NOT_VERIFYING
if the authprompt gets reset for some other reason in the interim.

This commit changes the check to be more precise. We now only skip
the fade-in, if we're already faded in, and we only skip the reset if
we're already reset.

https://bugzilla.gnome.org/show_bug.cgi?id=753181
This commit is contained in:
Ray Strode 2015-08-04 09:53:04 -04:00
parent d14548eb01
commit 84509886f7

View File

@ -874,7 +874,7 @@ const LoginDialog = new Lang.Class({
},
_loginScreenSessionActivated: function() {
if (this._authPrompt.verificationStatus != AuthPrompt.AuthPromptStatus.VERIFICATION_SUCCEEDED)
if (this.actor.opacity == 255 && this._authPrompt.verificationStatus == AuthPrompt.AuthPromptStatus.NOT_VERIFYING)
return;
Tweener.addTween(this.actor,
@ -891,7 +891,8 @@ const LoginDialog = new Lang.Class({
},
onUpdateScope: this,
onComplete: function() {
this._authPrompt.reset();
if (this._authPrompt.verificationStatus != AuthPrompt.AuthPromptStatus.NOT_VERIFYING)
this._authPrompt.reset();
},
onCompleteScope: this });
},