Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't accidentally create InlineChatFileCreatePreviewWidget when hiding it #203830

Merged
merged 1 commit into from
Jan 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -924,7 +924,7 @@ export class InlineChatController implements IEditorContribution {
this._ctxLastFeedbackKind.reset();
this._ctxSupportIssueReporting.reset();

this._zone.value.hide();
this._zone.rawValue?.hide();

// Return focus to the editor only if the current focus is within the editor widget
if (this._editor.hasWidgetFocus()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,7 @@ export class LivePreviewStrategy extends EditModeStrategy {
if (response.untitledTextModel && !response.untitledTextModel.isDisposed()) {
this._previewZone.value.showCreation(this._session.wholeRange.value.getStartPosition().delta(-1), response.untitledTextModel);
} else {
this._previewZone.value.hide();
this._previewZone.rawValue?.hide();
}

return this._updateDiffZones();
Expand Down Expand Up @@ -526,7 +526,7 @@ export class LiveStrategy extends EditModeStrategy {
if (response.untitledTextModel && !response.untitledTextModel.isDisposed()) {
this._previewZone.value.showCreation(this._session.wholeRange.value.getStartPosition().delta(-1), response.untitledTextModel);
} else {
this._previewZone.value.hide();
this._previewZone.rawValue?.hide();
}

this._progressiveEditingDecorations.clear();
Expand Down