screenShield: Move opening of screen shield to key press
This makes the screen shield much more responsive. https://bugzilla.gnome.org/show_bug.cgi?id=686740
This commit is contained in:
parent
ddced79475
commit
dde20f0c76
@ -435,8 +435,8 @@ const ScreenShield = new Lang.Class({
|
|||||||
name: 'lockScreenGroup',
|
name: 'lockScreenGroup',
|
||||||
visible: false,
|
visible: false,
|
||||||
});
|
});
|
||||||
this._lockScreenGroup.connect('key-release-event',
|
this._lockScreenGroup.connect('key-press-event',
|
||||||
Lang.bind(this, this._onLockScreenKeyRelease));
|
Lang.bind(this, this._onLockScreenKeyPress));
|
||||||
this._lockScreenGroup.connect('scroll-event',
|
this._lockScreenGroup.connect('scroll-event',
|
||||||
Lang.bind(this, this._onLockScreenScroll));
|
Lang.bind(this, this._onLockScreenScroll));
|
||||||
Main.ctrlAltTabManager.addGroup(this._lockScreenGroup, _("Lock"), 'changes-prevent-symbolic');
|
Main.ctrlAltTabManager.addGroup(this._lockScreenGroup, _("Lock"), 'changes-prevent-symbolic');
|
||||||
@ -590,7 +590,7 @@ const ScreenShield = new Lang.Class({
|
|||||||
return this._isModal;
|
return this._isModal;
|
||||||
},
|
},
|
||||||
|
|
||||||
_onLockScreenKeyRelease: function(actor, event) {
|
_onLockScreenKeyPress: function(actor, event) {
|
||||||
let symbol = event.get_key_symbol();
|
let symbol = event.get_key_symbol();
|
||||||
|
|
||||||
// Do nothing if the lock screen is not fully shown.
|
// Do nothing if the lock screen is not fully shown.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user