mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-20 16:49:06 +01:00
This commit is contained in:
@@ -1465,11 +1465,6 @@ export class InlineChatController2 implements IEditorContribution {
|
||||
this._store.dispose();
|
||||
}
|
||||
|
||||
toggleWidgetUntilNextRequest() {
|
||||
const value = this._showWidgetOverrideObs.get();
|
||||
this._showWidgetOverrideObs.set(!value, undefined);
|
||||
}
|
||||
|
||||
getWidgetPosition(): Position | undefined {
|
||||
return this._zone.rawValue?.position;
|
||||
}
|
||||
@@ -1485,11 +1480,18 @@ export class InlineChatController2 implements IEditorContribution {
|
||||
async run(arg?: InlineChatRunOptions): Promise<boolean> {
|
||||
assertType(this._editor.hasModel());
|
||||
|
||||
this.markActiveController();
|
||||
|
||||
const uri = this._editor.getModel().uri;
|
||||
const session = this._inlineChatSessions.getSession2(uri)
|
||||
?? await this._inlineChatSessions.createSession2(this._editor, uri, CancellationToken.None);
|
||||
|
||||
const existingSession = this._inlineChatSessions.getSession2(uri);
|
||||
if (existingSession) {
|
||||
await existingSession.editingSession.accept();
|
||||
existingSession.dispose();
|
||||
}
|
||||
|
||||
this.markActiveController();
|
||||
|
||||
const session = await this._inlineChatSessions.createSession2(this._editor, uri, CancellationToken.None);
|
||||
|
||||
// ADD diagnostics
|
||||
const entries: IChatRequestVariableEntry[] = [];
|
||||
|
||||
Reference in New Issue
Block a user