unlock: Don't show prompt on shifty key presses
Shift, caps-lock and friends change the capitalization of following key presses. It is unexpected for those keys to have side-effects, so don't switch to the prompt when they are pressed. https://gitlab.gnome.org/GNOME/gnome-shell/issues/2215
This commit is contained in:
parent
0d766dcf70
commit
8834088f3b
@ -593,6 +593,13 @@ var UnlockDialog = GObject.registerClass({
|
||||
(this._promptBox && this._promptBox.visible))
|
||||
return Clutter.EVENT_PROPAGATE;
|
||||
|
||||
const { keyval } = keyEvent;
|
||||
if (keyval === Clutter.KEY_Shift_L ||
|
||||
keyval === Clutter.KEY_Shift_R ||
|
||||
keyval === Clutter.KEY_Shift_Lock ||
|
||||
keyval === Clutter.KEY_Caps_Lock)
|
||||
return Clutter.EVENT_PROPAGATE;
|
||||
|
||||
let unichar = keyEvent.unicode_value;
|
||||
|
||||
this._showPrompt();
|
||||
|
Loading…
Reference in New Issue
Block a user