ScreenShield: move lock status handling to use session mode

Have distinct session modes for the lock screen and the unlock dialog,
and rework the logic in ScreenShield to have the lock-screen mode stack
onto the unlock-dialog mode (where applicable)

https://bugzilla.gnome.org/show_bug.cgi?id=682542
This commit is contained in:
Giovanni Campagna
2012-08-26 16:53:08 +02:00
parent 09e3aed770
commit 8cf9baa132
4 changed files with 76 additions and 58 deletions

View File

@ -343,8 +343,8 @@ const ScreenSaverDBus = new Lang.Class({
_init: function() {
this.parent();
Main.screenShield.connect('lock-status-changed', Lang.bind(this, function(shield, locked) {
this._dbusImpl.emit_signal('ActiveChanged', GLib.Variant.new('(b)', [locked]));
Main.screenShield.connect('lock-status-changed', Lang.bind(this, function(shield) {
this._dbusImpl.emit_signal('ActiveChanged', GLib.Variant.new('(b)', [shield.locked]));
}));
this._dbusImpl = Gio.DBusExportedObject.wrapJSObject(ScreenSaverIface, this);