File tree Expand file tree Collapse file tree 1 file changed +9
-2
lines changed
src/vs/workbench/contrib/notebook/browser/contrib/troubleshoot Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -183,7 +183,7 @@ export class TroubleshootController extends Disposable implements INotebookEdito
183
183
overlayContainer . appendChild ( topLine ) ;
184
184
185
185
const getLayoutInfo = ( ) => {
186
- const eol = cell . textModel ? .getEOL ( ) === '\n' ? 'LF' : 'CRLF' ;
186
+ const eol = cell . textBuffer . getEOL ( ) === '\n' ? 'LF' : 'CRLF' ;
187
187
const scrollTop = this . _notebookEditor . getAbsoluteTopOfElement ( cell ) ;
188
188
return `cell #${ index } (handle: ${ cell . handle } ) | AbsoluteTopOfElement: ${ scrollTop } px | EOL: ${ eol } ` ;
189
189
} ;
@@ -230,7 +230,14 @@ export class TroubleshootController extends Disposable implements INotebookEdito
230
230
this . _localStore . add ( cell . onDidChangeLayout ( ( e ) => {
231
231
updateLayout ( ) ;
232
232
} ) ) ;
233
-
233
+ this . _localStore . add ( cell . textBuffer . onDidChangeContent ( ( ) => {
234
+ updateLayout ( ) ;
235
+ } ) ) ;
236
+ if ( cell . textModel ) {
237
+ this . _localStore . add ( cell . textModel . onDidChangeContent ( ( ) => {
238
+ updateLayout ( ) ;
239
+ } ) ) ;
240
+ }
234
241
this . _localStore . add ( this . _notebookEditor . onDidChangeLayout ( ( ) => {
235
242
updateLayout ( ) ;
236
243
} ) ) ;
You can’t perform that action at this time.
0 commit comments