Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
registerKeybindings(keybindings: KeybindingRegistry): void {
// unregister Ctrl + F pseudo command for terminal widget.
keybindings.unregisterKeybinding({
command: KeybindingRegistry.PASSTHROUGH_PSEUDO_COMMAND,
keybinding: KeyCode.createKeyCode({ key: Key.KEY_F, ctrl: true }).toString(),
context: TerminalKeybindingContexts.terminalActive
});
keybindings.registerKeybinding({
command: TerminalSearchCommands.TERMINAL_FIND_TEXT.id,
keybinding: 'ctrlcmd+f',
context: TerminalKeybindingContexts.terminalActive
});
keybindings.registerKeybinding({
command: TerminalSearchCommands.TERMINAL_FIND_TEXT_CANCEL.id,
keybinding: 'esc',
context: TerminalSearchKeybindingContext.disableSearch
});
}
}
registerKeybindings(keybindings: KeybindingRegistry): void {
// unregister Ctrl + F pseudo command for terminal widget.
keybindings.unregisterKeybinding({
command: KeybindingRegistry.PASSTHROUGH_PSEUDO_COMMAND,
keybinding: KeyCode.createKeyCode({ key: Key.KEY_F, ctrl: true }).toString(),
context: TerminalKeybindingContexts.terminalActive
});
keybindings.registerKeybinding({
command: TerminalSearchCommands.TERMINAL_FIND_TEXT.id,
keybinding: 'ctrlcmd+f',
context: TerminalKeybindingContexts.terminalActive
});
keybindings.registerKeybinding({
command: TerminalSearchCommands.TERMINAL_FIND_TEXT_CANCEL.id,
keybinding: 'esc',
context: TerminalSearchKeybindingContext.disableSearch
});
}
}