Add reply to the comments view context menu (#207156)

Fixes microsoft/vscode-pull-request-github#5698
This commit is contained in:
Alex Ross
2024-03-08 12:39:44 +01:00
committed by GitHub
parent 6c19c00357
commit 59857a62e6
12 changed files with 161 additions and 88 deletions

View File

@@ -20,6 +20,7 @@ import type * as vscode from 'vscode';
import { ExtHostCommentsShape, IMainContext, MainContext, CommentThreadChanges, CommentChanges } from './extHost.protocol';
import { ExtHostCommands } from './extHostCommands';
import { checkProposedApiEnabled } from 'vs/workbench/services/extensions/common/extensions';
import { MarshalledCommentThread } from 'vs/workbench/common/comments';
type ProviderHandle = number;
@@ -53,16 +54,17 @@ export function createExtHostComments(mainContext: IMainContext, commands: ExtHo
return commentController.value;
} else if (arg && arg.$mid === MarshalledId.CommentThread) {
const commentController = this._commentControllers.get(arg.commentControlHandle);
const marshalledCommentThread: MarshalledCommentThread = arg;
const commentController = this._commentControllers.get(marshalledCommentThread.commentControlHandle);
if (!commentController) {
return arg;
return marshalledCommentThread;
}
const commentThread = commentController.getCommentThread(arg.commentThreadHandle);
const commentThread = commentController.getCommentThread(marshalledCommentThread.commentThreadHandle);
if (!commentThread) {
return arg;
return marshalledCommentThread;
}
return commentThread.value;