File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed
src/vs/workbench/contrib/notebook/browser/contrib/find Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -91,6 +91,7 @@ class NotebookFindWidget extends SimpleFindReplaceWidget implements INotebookEdi
9191 DOM . append ( this . _notebookEditor . getDomNode ( ) , this . getDomNode ( ) ) ;
9292 this . _findWidgetFocused = KEYBINDING_CONTEXT_NOTEBOOK_FIND_WIDGET_FOCUSED . bindTo ( contextKeyService ) ;
9393 this . _register ( this . _findInput . onKeyDown ( ( e ) => this . _onFindInputKeyDown ( e ) ) ) ;
94+ this . _register ( this . _replaceInput . onKeyDown ( ( e ) => this . _onReplaceInputKeyDown ( e ) ) ) ;
9495
9596 this . _register ( this . _state . onFindReplaceStateChange ( ( e ) => {
9697 this . onInputChanged ( ) ;
@@ -134,6 +135,14 @@ class NotebookFindWidget extends SimpleFindReplaceWidget implements INotebookEdi
134135 }
135136 }
136137
138+ private _onReplaceInputKeyDown ( e : IKeyboardEvent ) : void {
139+ if ( e . equals ( KeyCode . Enter ) ) {
140+ this . replaceOne ( ) ;
141+ e . preventDefault ( ) ;
142+ return ;
143+ }
144+ }
145+
137146 protected onInputChanged ( ) : boolean {
138147 this . _state . change ( { searchString : this . inputValue } , false ) ;
139148 // this._findModel.research();
You can’t perform that action at this time.
0 commit comments