Add ability to handle enter key propagation for input model components (#7524)

* Add ability to stop enter key propagation for input model components

* Fix spacing

* onInputEntered -> onEnterKeyPressed
This commit is contained in:
Charles Gagnon
2019-10-07 12:05:43 -07:00
committed by GitHub
parent effa50a9bd
commit 5454917569
7 changed files with 73 additions and 1 deletions

View File

@@ -514,6 +514,11 @@ declare module 'sqlops' {
columns?: number;
min?: number;
max?: number;
/**
* Whether to stop key event propagation when enter is pressed in the input box. Leaving this as false
* means the event will propagate up to any parents that have handlers (such as validate on Dialogs)
*/
stopEnterPropagation?: boolean;
}
export interface TableColumn {
@@ -703,6 +708,10 @@ declare module 'sqlops' {
export interface InputBoxComponent extends Component, InputBoxProperties {
onTextChanged: vscode.Event<any>;
/**
* Event that's fired whenever enter is pressed within the input box
*/
onEnterKeyPressed: vscode.Event<string>;
}
export interface RadioButtonComponent extends Component, RadioButtonProperties {