mirror of
https://github.com/Microsoft/vscode
synced 2024-08-27 04:49:35 +00:00
parent
277e80be94
commit
b8e69611bd
|
@ -16,7 +16,6 @@ import { ExtensionIdentifier, IExtensionDescription } from 'vs/platform/extensio
|
|||
import { ExtHostDocuments } from 'vs/workbench/api/common/extHostDocuments';
|
||||
import * as extHostTypeConverter from 'vs/workbench/api/common/extHostTypeConverters';
|
||||
import * as types from 'vs/workbench/api/common/extHostTypes';
|
||||
import { checkProposedApiEnabled } from 'vs/workbench/services/extensions/common/extensions';
|
||||
import type * as vscode from 'vscode';
|
||||
import { ExtHostCommentsShape, IMainContext, MainContext, CommentThreadChanges, CommentChanges } from './extHost.protocol';
|
||||
import { ExtHostCommands } from './extHostCommands';
|
||||
|
@ -338,12 +337,10 @@ export function createExtHostComments(mainContext: IMainContext, commands: ExtHo
|
|||
private _state?: vscode.CommentThreadState;
|
||||
|
||||
get state(): vscode.CommentThreadState {
|
||||
checkProposedApiEnabled(this.extensionDescription, 'commentsResolvedState');
|
||||
return this._state!;
|
||||
}
|
||||
|
||||
set state(newState: vscode.CommentThreadState) {
|
||||
checkProposedApiEnabled(this.extensionDescription, 'commentsResolvedState');
|
||||
this._state = newState;
|
||||
this.modifications.state = newState;
|
||||
this._onDidUpdateCommentThread.fire();
|
||||
|
|
|
@ -8,7 +8,6 @@
|
|||
export const allApiProposals = Object.freeze({
|
||||
authSession: 'https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.authSession.d.ts',
|
||||
codiconDecoration: 'https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.codiconDecoration.d.ts',
|
||||
commentsResolvedState: 'https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.commentsResolvedState.d.ts',
|
||||
contribCommentEditorActionsMenu: 'https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.contribCommentEditorActionsMenu.d.ts',
|
||||
contribCommentPeekContext: 'https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.contribCommentPeekContext.d.ts',
|
||||
contribCommentThreadAdditionalMenu: 'https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.contribCommentThreadAdditionalMenu.d.ts',
|
||||
|
|
13
src/vscode-dts/vscode.d.ts
vendored
13
src/vscode-dts/vscode.d.ts
vendored
|
@ -15222,6 +15222,14 @@ declare module 'vscode' {
|
|||
Preview = 1
|
||||
}
|
||||
|
||||
/**
|
||||
* The state of a comment thread.
|
||||
*/
|
||||
export enum CommentThreadState {
|
||||
Unresolved = 0,
|
||||
Resolved = 1
|
||||
}
|
||||
|
||||
/**
|
||||
* A collection of {@link Comment comments} representing a conversation at a particular range in a document.
|
||||
*/
|
||||
|
@ -15279,6 +15287,11 @@ declare module 'vscode' {
|
|||
*/
|
||||
label?: string;
|
||||
|
||||
/**
|
||||
* The optional state of a comment thread, which may affect how the comment is displayed.
|
||||
*/
|
||||
state?: CommentThreadState;
|
||||
|
||||
/**
|
||||
* Dispose this comment thread.
|
||||
*
|
||||
|
|
|
@ -1,24 +0,0 @@
|
|||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the MIT License. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
declare module 'vscode' {
|
||||
|
||||
// https://github.com/microsoft/vscode/issues/127473
|
||||
|
||||
/**
|
||||
* The state of a comment thread.
|
||||
*/
|
||||
export enum CommentThreadState {
|
||||
Unresolved = 0,
|
||||
Resolved = 1
|
||||
}
|
||||
|
||||
export interface CommentThread {
|
||||
/**
|
||||
* The optional state of a comment thread, which may affect how the comment is displayed.
|
||||
*/
|
||||
state?: CommentThreadState;
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue