mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-27 17:46:05 -05:00
FIX: Pressing Ctrl+F twice should close Discourse search window
This commit is contained in:
parent
8dc0fa97d4
commit
2d1c21755f
1 changed files with 3 additions and 3 deletions
|
@ -368,14 +368,14 @@ export default {
|
|||
},
|
||||
|
||||
_stopCallback() {
|
||||
const oldStopCallback = this.keyTrapper.stopCallback;
|
||||
const oldStopCallback = this.keyTrapper.prototype.stopCallback;
|
||||
|
||||
this.keyTrapper.stopCallback = function(e, element, combo) {
|
||||
this.keyTrapper.prototype.stopCallback = function(e, element, combo, sequence) {
|
||||
if ((combo === 'ctrl+f' || combo === 'command+f') && element.id === 'search-term') {
|
||||
return false;
|
||||
}
|
||||
|
||||
return oldStopCallback(e, element, combo);
|
||||
return oldStopCallback(e, element, combo, sequence);
|
||||
};
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue