ScreenShield: remove curtain animation when hiding without animation

If we don't remove the animation, we might leave a pending call
to _lockScreenShown() which would confuse our state tracking into
thinking we're active when we're not.

https://bugzilla.gnome.org/show_bug.cgi?id=700901
This commit is contained in:
Giovanni Campagna 2013-06-03 23:45:31 +02:00
parent 04f1f5f94b
commit 7652f4272c

View File

@ -882,6 +882,8 @@ const ScreenShield = new Lang.Class({
this._lockScreenState = MessageTray.State.HIDING;
Tweener.removeTweens(this._lockScreenGroup);
if (animate) {
// Tween the lock screen out of screen
// if velocity is not specified (i.e. we come here from pressing ESC),
@ -894,7 +896,6 @@ const ScreenShield = new Lang.Class({
velocity = Math.max(min_velocity, velocity);
let time = (delta / velocity) / 1000;
Tweener.removeTweens(this._lockScreenGroup);
Tweener.addTween(this._lockScreenGroup,
{ y: -h,
time: time,