Add tab pin status

This commit is contained in:
Logan Ramos
2022-02-22 10:52:46 -05:00
parent 198682cfac
commit cc5519bc3f
4 changed files with 57 additions and 17 deletions

View File

@@ -638,6 +638,7 @@ export interface IEditorTabDto {
resource?: UriComponents;
editorId?: string;
isActive: boolean;
isPinned: boolean;
isDirty: boolean;
kind: TabKind;
additionalResourcesAndViewIds: { resource?: UriComponents; viewId?: string }[];

View File

@@ -17,6 +17,7 @@ export interface IEditorTab {
resource: vscode.Uri | undefined;
viewId: string | undefined;
isActive: boolean;
isPinned: boolean;
kind: TabKind;
isDirty: boolean;
additionalResourcesAndViewIds: { resource: vscode.Uri | undefined; viewId: string | undefined }[];
@@ -85,7 +86,7 @@ export class ExtHostEditorTabs implements IExtHostEditorTabs {
this._onDidChangeTabGroup.fire();
}
private createExtHostTabObject(tabDto: IEditorTabDto) {
private createExtHostTabObject(tabDto: IEditorTabDto): IEditorTab {
return Object.freeze({
label: tabDto.label,
viewColumn: typeConverters.ViewColumn.to(tabDto.viewColumn),
@@ -95,6 +96,7 @@ export class ExtHostEditorTabs implements IExtHostEditorTabs {
isActive: tabDto.isActive,
kind: tabDto.kind,
isDirty: tabDto.isDirty,
isPinned: tabDto.isPinned,
move: async (index: number, viewColumn: ViewColumn) => {
this._proxy.$moveTab(tabDto, index, typeConverters.ViewColumn.from(viewColumn));
// TODO: Need an on did change tab event at the group level