keyboard: Do key presses on actual key press
It was mistakenly connecting twice to the 'released' signal. Also, move level changes to key release, since it will be more convenient to hook latched states on long press. https://gitlab.gnome.org/GNOME/gnome-shell/issues/46
This commit is contained in:
@ -807,14 +807,14 @@ var Keyboard = new Lang.Class({
|
||||
|
||||
let actor = extraButton.keyButton;
|
||||
|
||||
extraButton.connect('pressed', Lang.bind(this, function() {
|
||||
if (keyval != null)
|
||||
this._keyboardController.keyvalPress(keyval);
|
||||
}));
|
||||
extraButton.connect('released', Lang.bind(this, function() {
|
||||
if (switchToLevel != null)
|
||||
this._onLevelChanged(switchToLevel);
|
||||
else if (keyval != null)
|
||||
this._keyboardController.keyvalPress(keyval);
|
||||
}));
|
||||
extraButton.connect('released', Lang.bind(this, function() {
|
||||
if (keyval != null)
|
||||
this._keyboardController.keyvalRelease(keyval);
|
||||
else if (action == 'hide')
|
||||
this.hide();
|
||||
|
Reference in New Issue
Block a user