mirror of
https://github.com/microsoft/vscode.git
synced 2026-02-25 20:24:04 +00:00
Don't render the inline edits in diff editors (#230710)
This commit is contained in:
@@ -43,20 +43,24 @@ export class ChatEditorController extends Disposable implements IEditorContribut
|
||||
return;
|
||||
}
|
||||
const model = this._editor.getModel();
|
||||
if (this._editor.getOption(EditorOption.inDiffEditor)) {
|
||||
this._clearRendering();
|
||||
return;
|
||||
}
|
||||
this._sessionStore.add(model.onDidChangeContent(() => this._updateSessionDecorations()));
|
||||
this._updateSessionDecorations();
|
||||
}
|
||||
|
||||
private _updateSessionDecorations(): void {
|
||||
if (!this._editor.hasModel()) {
|
||||
this._decorations.clear();
|
||||
this._clearRendering();
|
||||
return;
|
||||
}
|
||||
const model = this._editor.getModel();
|
||||
const editingSession = this._chatEditingService.getEditingSession(model.uri);
|
||||
const entry = this._getEntry(editingSession, model);
|
||||
if (!entry) {
|
||||
this._decorations.clear();
|
||||
this._clearRendering();
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user