mirror of
https://github.com/microsoft/vscode.git
synced 2026-08-19 14:22:19 +01:00
consider cancel state when recomputing response type context key (#226409)
re https://github.com/microsoft/vscode-copilot/issues/7324
This commit is contained in:
@@ -527,7 +527,12 @@ export class ReportIssueAction extends AbstractInlineChatAction {
|
||||
id: MENU_INLINE_CHAT_WIDGET_STATUS,
|
||||
group: '0_main',
|
||||
order: 6,
|
||||
when: ContextKeyExpr.and(CTX_INLINE_CHAT_VISIBLE, CTX_INLINE_CHAT_SUPPORT_REPORT_ISSUE, CTX_INLINE_CHAT_REQUEST_IN_PROGRESS.negate())
|
||||
when: ContextKeyExpr.and(
|
||||
CTX_INLINE_CHAT_VISIBLE,
|
||||
CTX_INLINE_CHAT_SUPPORT_REPORT_ISSUE,
|
||||
CTX_INLINE_CHAT_RESPONSE_TYPE.notEqualsTo(InlineChatResponseType.None),
|
||||
CTX_INLINE_CHAT_REQUEST_IN_PROGRESS.negate()
|
||||
)
|
||||
}]
|
||||
});
|
||||
}
|
||||
|
||||
@@ -921,7 +921,7 @@ export class InlineChatController implements IEditorContribution {
|
||||
|
||||
let responseType = InlineChatResponseType.None;
|
||||
for (const request of this._session.chatModel.getRequests()) {
|
||||
if (!request.response) {
|
||||
if (!request.response || request.response.isCanceled) {
|
||||
continue;
|
||||
}
|
||||
responseType = InlineChatResponseType.Messages;
|
||||
|
||||
Reference in New Issue
Block a user