mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-24 02:28:34 +01:00
replace draft properties with labels in CommentThread and Comment
This commit is contained in:
@@ -127,6 +127,7 @@ export interface MainThreadCommentsShape extends IDisposable {
|
||||
$updateCommentThreadCommands(handle: number, commentThreadHandle: number, acceptInputCommands: modes.Command[]): void;
|
||||
$updateCommentThreadCollapsibleState(handle: number, commentThreadHandle: number, collapseState: modes.CommentThreadCollapsibleState): void;
|
||||
$updateCommentThreadRange(handle: number, commentThreadHandle: number, range: IRange): void;
|
||||
$updateCommentThreadLabel(handle: number, commentThreadHandle: number, label: string): void;
|
||||
$registerDocumentCommentProvider(handle: number, features: CommentProviderFeatures): void;
|
||||
$unregisterDocumentCommentProvider(handle: number): void;
|
||||
$registerWorkspaceCommentProvider(handle: number, extensionId: ExtensionIdentifier): void;
|
||||
|
||||
@@ -308,6 +308,17 @@ export class ExtHostCommentThread implements vscode.CommentThread {
|
||||
return this._range;
|
||||
}
|
||||
|
||||
private _label: string;
|
||||
|
||||
get label(): string {
|
||||
return this._label;
|
||||
}
|
||||
|
||||
set label(label: string) {
|
||||
this._label = label;
|
||||
this._proxy.$updateCommentThreadLabel(this._commentControlHandle, this.handle, this._label);
|
||||
}
|
||||
|
||||
private _comments: vscode.Comment[] = [];
|
||||
|
||||
get comments(): vscode.Comment[] {
|
||||
@@ -557,7 +568,8 @@ function convertToModeComment(vscodeComment: vscode.Comment, commandsConverter:
|
||||
userIconPath: iconPath,
|
||||
isDraft: vscodeComment.isDraft,
|
||||
editCommand: vscodeComment.editCommand ? commandsConverter.toInternal(vscodeComment.editCommand) : undefined,
|
||||
deleteCommand: vscodeComment.editCommand ? commandsConverter.toInternal(vscodeComment.deleteCommand) : undefined
|
||||
deleteCommand: vscodeComment.editCommand ? commandsConverter.toInternal(vscodeComment.deleteCommand) : undefined,
|
||||
label: vscodeComment.label
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user